4
\$\begingroup\$

I have an animation clip I made with Mechanim. But when I changed the hierarchy of the objects in the children, it stopped working!

The text says ( Missing! )

Why is it breaking? How can I fix it?

\$\endgroup\$

1 Answer 1

5
\$\begingroup\$

In Unity, Animations are bound by name, so if you change the name of any object, or move the object to a different parent (thereby changing the path), the animation will break.

Do not attempt to use a 'find and replace' feature with a text editor, as this is known to cause corruption.

Luckily, Unity has a built-in (though somewhat hidden) API for editing animations. If you have a big project and a team, one of your developers ought to learn this API and make an editor to handle this.

If not, you can use this free tool, which I have tried and works well (saving me hours of time by not needing to redo my animations!)

https://github.com/s-m-k/Unity-Animation-Hierarchy-Editor

(Note: tool is open source)

\$\endgroup\$
1
  • \$\begingroup\$ I had the issue when I made model and animations in Blender and exported to FBX to be imported in Unity. Unity properly found everything, but all animations had this issue, so I needed to sit and remap it. Thanks for the link to the editor script. Certainly helped. But it would be nice to find the cause for this madness, so it could be avoided altogether :) \$\endgroup\$
    – Eldamir
    Sep 4, 2020 at 4:26

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .