Animation not played completely when root motion on
I have a little problem with my character when trying to make it turns back. I currently have a non looping turning back animation with root motion enabled. This anim is controlled in the anim BP state machine and is launched when the character IsRotating var is true.
The issue is to know when the animation is completed.
I tried to use an anim notify at the last frame of the anim which fire an event setting back to False characterIsRotating var and so exiting the turn back animation. It works but the animation stops before it actually ends, having the character not totally 180° rotated whereas it should be. I tried an alternative way, by using a Get Relevant Anim Time Remaining <= 0 to exit the anim sate but again, it stops the animation too early.
Any idea how to detect accurately when an animation ends?
UPDATE: seems the root motion option cause the issue, when off the animation is played completely. The question is now how to get the animation plays completely when using root motion.
Ok the issues is caused by the blending. When I set the blend time to 0 in the transition rules, the animation is played completely even with root motion On. So I guess if I still want my animation to blend, I have to add a little extra time in the anim before and after rotating the root bone so the blend will not affect the rotation movement.
answered Dec 01 '15 at 11:18 AM
im doing this differently but it might help you. If you're using montages which I am, you can get current montage and then get length.
So whenever I set a var in my CharBP to true which I know will carry over to my AnimBP and start a montage, I get the montage play length in the charBP and set a timer for that length which sets the variable that played the montage to false after that amount of time. ending the root motion anim after its done playting.
answered Nov 30 '15 at 09:14 PM
Follow this question
Once you sign in you will be able to subscribe for any updates here