Using Animation Override Tracks and Avatar Masking
This workflow demonstrates how to use an Animation Override track and an Avatar Mask to replace the upper-body animation of an Animation track. Use this technique to animate a humanoid character to, for example, run and carry an object.
This workflow does not show how to create an Avatar mask. This workflow only demonstrates how to use an Avatar Mask when creating a Timeline instance. This workflow also assumes that you have already created a Timeline instance with a simple Animation clip, such as a walk or run cycle, on an Animation track bound to a humanoid.
Right-click the Animation track and select Add Override Track from the context menu. An Animation Override track, named Override 0, is linked to the selected Animation track. Notice that the Animation Override track is not bound to a GameObject. Since the Override track is linked to the Animation track above, the Override track is bound to the same GameObject: the Guard humanoid.
From your project, drag an animation clip with upper-body animation into the Override track. For example, drag an animation of a humanoid standing still and waving their arms. Position and resize the Waving_Arms clip as appropriate.
Play the Timeline instance. The Waving_Arms clip completely overrides the Run_Forward clip. To combine the lower-body animation from the Run_Forward clip with the upper-body animation from the Waving_Arms clip, specify an Avatar Mask for the Animation Override track.
From the project, drag an Avatar Mask into the Avatar Mask property in the Inspector window. Activate the Apply Avatar Mask checkbox. An Avatar Mask icon appears beside the track name.
Play the Timeline instance. On the Guard humanoid, the upper-body animation is taken from the Waving_Arms clip and the lower-body animation is from the Run_Forward clip. To temporarily disable the Avatar Mask, click the Avatar Mask icon.
Is something described here not working as you expect it to? It might be a Known Issue. Please check with the Issue Tracker at issuetracker.unity3d.com.
Thanks for letting us know! This page has been marked for review based on your feedback.
If you have time, you can provide more information to help us fix the problem faster.
You've told us this page needs code samples. If you'd like to help us further, you could provide a code sample, or tell us about what kind of code sample you'd like to see:
You've told us there are code samples on this page which don't work. If you know how to fix it, or have something better we could use instead, please let us know:
You've told us there is information missing from this page. Please tell us more about what's missing:
You've told us there is incorrect information on this page. If you know what we should change to make it correct, please tell us:
You've told us this page has unclear or confusing information. Please tell us more about what you found unclear or confusing, or let us know how we could make it clearer:
You've told us there is a spelling or grammar error on this page. Please tell us what's wrong:
You've told us this page has a problem. Please tell us more about what's wrong:
Thanks for helping to make the Unity documentation better!