Programming RPG game, I would like to control animation speed in relation to its duration.
For example, character has to cast spell in X seconds. I would like to play the animation state so fast so the animation is finished exactly in X seconds.
-X is determined right before starting an animation.
-I have multiple animations for multiple characters so I would like to avoid doing this via manual calculation and adjustment of animation clip speed in animator
How can I implement this behavior?