Download

Improved animation blending.

Hey! I currently have a running animation, and an attack animation.
When both are played I seperate them with a “layered blend per bone” that’s filtered at the character’s spine.
However, this ends up with a very robotic and unnatural blending of the two animations, as if the upper half and the lower half are two seperate actors, rather than one whole character.
How can I blend the two animations together more fluidly rather than seperate them in half?

Yeah this is one of the problems one has to deal with as far as “video game” animation goes and at times one needs to do more thinking than doing and the first thought the current state of the character animation is not the as critical as to how it enters into and out of the state. Most think I’ll just blend from state A to state B and things will work out just fine but as you have noticed the result is not ideal as to human movement dynamics.

In general for state changes you need to have 3 state changes in the migration path usually referred to as a corrective pose so for example going from an idle to a run you would be starting out in the idle state into a run start corrective pose, can be single frame or animated, into the run state.

Corrective or additive animations are generally authored based on what you see as a weak or unnatural state change and the first impulse is to change values between the two where what is needed is a key framed animation take to force the blend to occur more natural and it’s that take you would iterate.

Is there a way to adjust the weight the animations per bone? E.G. to create a gradual transition, 25% at the first bone, 50% at the next, then 75% at the one before the second animation completely takes over.

I know about blendspaces, but I’m unsure if I can make them play along with animation montages?

Well the best option is a corrective and since video game animation is my thing is the easier way to go for me but sure if you want to do blends by weight you can do that as well.

Under Layerset up the default is 1 array filter that you can add elements say for left eye and right eye. If on the other hand you add a pin to the per bone you can add a take and the take will have it’s own branch filters. You should also notice that the blend now has two blend weights and this is where you can plug in your percentage blends

Another though is you could could try adding in secondary motion using the physics asset. I not tried doing it my self but I’ve seen it done. You can apply a small amount of physics based secondary motion to the hips and it should by it’s behaviour correct the blend for you. Added bonus it would be included in all movements

Good start
https://youtube.com/watch?v=fXoE9vUylCM
Just google Unreal 4 secondary motion

LOL you got me looking

The ticket

https://www.youtube.com/watch?time_continue=18&v=N1tDjbFXeOo

To better elucidate,
are you just having unnatural movement between the top motion and bottom during the attack?

If so, firt thing first any attack should attempt to adjust the bottom to be in line with the attack. Technically when fighting you naturally move in the position from which you deliver the best swing. To achieve this think of it as the same theory of an aim offset, except driven by the attack.
Align the position, continue wi xq,th the attack - which I suppose is exaclty that which FrankyV was pointing out.

Except, you maybe able to get away with just rotating the root bone. It all depends on how it’s set up.

Second, if you drive a melee swing with an aim offset or IK, you can apply a twist per bone layer to do arbitrarily what you described as a percentage without needing to do animations for it.
the idea is to lessen the twist as you get close to the pelvis, so that the blend no longer matters at all. It may be enough to implement so.ething like this for it to look good…

Yeah, you guys gave me some good insight here. Currently I was trying to blend a “passive” idle animation and running animation with the attack.

However the attack was animated to look fluid with a fighting pose. So I should probably instead have my character have 2 base poses, one for combat and one for idle.
Hopefully this should look more natural.

I also have some experience with IK’s back in the UDK days, I might look into how I can them for some of these cases.
E.G, link the legs and lock the feet in place so I can move the character’s hips without moving the feet through the ground.