What is the best method to get a Mecanim character play a custom animation

I have a character that is using mecanim to move around. I want the character to play a custom animation where he climbs out of a box. With the legacy system, I could easily tween the character to the correct position and use animation.Play() for him to climb out of the box.

Also, lets say I have a character, that is going to talk for 5 seconds, then after those seconds, I need him to play a falling animation. Through Legacy I could use an Ienumerator and yield for as long the animation was, and then play the animation.

So, what is the best way to solve this on a character that is using mecanim, without creating a messy Mecanim Controller?

I had the same problem this morning when I changed from 3 to 4. I wanted to just use my old animations like I use to.

All you have to do is select your model in the project folder then click on the rig tab.

Then select animation type as legacy.

Generation = Store in root (new)

Then click in animation tab and set up animations like you use to do in 3.

Then you can use crossfade, play and the like from the animation class.

I hope that helps :slight_smile: