OptimizeTransformHierarchy + Generic rigs

Is it possible to optimize a Generic rig with the OptimizeTransformhierarchy? Works fine on humanoids but on the generic stuff we have, half the mesh explodes…

We are on 5.3.5p1

I see this in the output…

it != transformToMark.end ()
UnityEngine.AnimatorUtility:OptimizeTransformHierarchy(GameObject, String[ ])

It’s definitely worked for me. Not sure what the error is :confused:

great, good to know. thanks.

I also met this problem before.
If any exposed name you provided can’t be found on the transform, this error shows up.
Try to pass in a null to the string[ ] exposedTransforms parameter to figure it out.