Improving BlendAction

Hey guys!

As you may already know JME’s new animation system has a BlendAction feature that is used to blend multiple animations together (like walk and run animations). But it requires the animations to have the same length otherwise it will internally stretch any animation that does not have the same length. Stretching animation might introduce a slow-motion side effect.

For example, here I am blending “walk” and “run” animations. The walk animation is 1.5 seconds, and the run animation is 0.5 seconds. BlendAction will internally stretch the run animation length to be equal to the walk animation. So the run animation will also be 1.5 seconds.

Here is the blending result:

Here you need to increase the speed as it blends toward run animation and vice versa.

I have made a PR to automate this, so BlendAction will automatically adjust the speed for you. It will calculate a factor to be applied to speed based on the current blend weight taken from blend space.

You can see the result:

Here is the PR:

6 Likes

Hey guys, do the embedded videos play fine for you?
It does not play as an embedded video for me but plays fine from youtube itself.

Plays fine for me.

1 Like

me2

Inspecting the connection, I noticed there were a bunch of 403 errors from YT down the road.

It’s odd but I noticed after I signed out from my YouTube account I can now play them o^O

1 Like