Get the root motion at a specific animation frame

Hey,

I’d like to know if there is a way for an editor script to get the (root) position of an object that is animated with mecanim using root motion.

Using gameobject.SampleAnimation or animator.Play changes the object attributes and local transform but doesn’t update the position.

Thanks!

This link will help you greatly, I imagine.

http://mecwarriors.com/2014/08/18/scripting-root-motion/

Essentially, Velocity = Displacement / Time.

You have velocity and time. Normalised Time is what you use I believe, for referring to a point in an animation. Which is basically between 0->1 Start to end.