Mecanim FAQ

General questions

We are using the legacy animation system for character animations. Should use Mecanim instead?

Mecanim is the main animation technology that will be used and developed by Unity from now on. The legacy system will not be updated significantly.


Why is an Animator added automatically to every mesh as it is imported?

Currently there is no way for you to change the default import settings but if you set the Rig to None in the import settings then the Animator component will not be added - you can do this with several files at once


Does the ordering of the layers matter?

Yes. Layers are evaluated from top to bottom in order. Layers set to override will always override the previous layers (based on their mask, if they have a mask)

Is the base layer weight always supposed to be one or should the weight be set to zero when another synced layer is run?

The base layer weight is always 1 but layers set to override will completely override the base layer.

What happens if a synced layer has a different length to the corresponding state in the base layer?

If layers have different lengths then they will become unsynchronised.

Is there any way to get a variable value from the controller without using the name string?

You can use integers to identify the states and parameters. Use the Animator.StringToHash function to get the integer identifier values. For example:

runState = Animator.StringToHash("Base Layer.Run");
animator.SetBool(runState, false);

Avatars and body Masks

Is there a way to define what bones should be part of a body mask?

Due to implementation details, this is currently not possible.

Is there a way to create AvatarIKGoals other than LeftFoot, RightFoot, LeftHand, RightHand?

This feature is planned for a future release.

Animations curves and events

Can you add animation events to Mecanim?

This is high in our priorities for future development. For the time being, we suggest using additional animation curves to simulate events approximately. Although this technique doesn't recreate events exactly, many of our users have reported it as useful.

How do animations that have Curves blend with those that don't?

When you have an animation with a curve and another animation without a curve, Unity will use the default value of the parameter connected to the curve to do blending. You can set default values for your parameters, so when blending takes place between a State that has a Curve Parameter and one that does not have one, it will blend between the curve value and the default parameter value. To set a default value for a Parameter, simply set its value in the Animator Tool window while not in LiveLink.

Page last updated: 2013-04-23