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.

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.

I tried with a delay, to wait a bit when the notify triggers the event then set false the rotating variable, but the anim still doesn’t play until the end.

I notice the animation play completely when the root motion is off, so the issue is not how to detect when the anim end. The issue is the root motion option which seems somehow to stop the animation before it should.

Yes, it’s set to Root motion for everything.

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.

you have the root motion enabled in the animBP?