New AnimLayerBlending

Hi there,
I was playing around with the new anim layer-blending tool.
The problem that occures is that one animation(walking backwards in this case) which is playing fine in the old state-graph-workflow (without blending layers) has some strange behaviour when added to one of the layers I’m trying to blend.
I tried different animations with this character but they all have the same behaviour when added (except walking forwards and idle).
Plus the strange movement only happens at the beginning and the end of when the animation should be playing, not in between loops.

Maybe someone can help me with what I’m missing out on?

Thanks :smiley:

Here’s the scene:
https://playcanvas.com/editor/scene/1271267

@Elliott , would you be able to look at this please?

Hi @madness,

This seems to be an issue that has cropped up in more than one place with the quaternion blending algorithm that’s used for layer blending. I’m currently investigating it, however if you’re in urgent need of a solution and don’t currently require the masking of your animations, I’d suggest using normal state transitions or blend trees to achieve the desired blending result. I’ll be working on a solution to release as soon as possible.

1 Like

Okay thanks, then I’ll work with blend trees for now.

Hi again, so I’ve been using blend trees for animations, and it seems to work pretty good. Ecxept for one thing: I’ve got 2 states in the blend tree that I need to switch since I can’t add turn animations into the move state.
By now I can transition between those 2 States (Travel, Turn) as you can see in the console as soon as you’re turning. But the turn animations won’t play in the Turn State.

Would be cool if you could have another look at this project.
note: in order to see the character you have to open 2 tabs since its connected via a server. (So basically you see the other person that joined that server but not yourself).

@Elliott

https://playcanvas.com/project/850344/overview/blendtreeproblem

Hi @madness,

Taking a look at your blend tree script, it looks like you’re using the parameter turn to control your Turn blend tree but also to transition between the Travel and Turn states. In this instance, if you’re in the Travel state and then transition to the Turn state by setting the turn parameter to 0, when you update the turn parameter to 1 or -1 in order to control the Turn blend tree, you’ll also be triggering the transition back to the Travel state. I’d suggest using a different parameter for your transition between the Travel and Turn states.

1 Like

Hi @Elliott ,
so that wasn’t it, but I found the problem this morning. I used pc.ANIM_BLEND_2D_DIRECTIONAL as blendtree type instead of pc.ANIM_BLEND_1D but the turn state acutally always just had one paramter. :smiley:

2 Likes