Version: 2019.3
Animator Controller
Animation States

Creating an AnimatorController

Animator Controller

You can view and set up character behavior from the Animator ControllerControls animation through Animation Layers with Animation State Machines and Animation Blend Trees, controlled by Animation Parameters. The same Animator Controller can be referenced by multiple models with Animator components. More info
See in Glossary
view (Menu: Window > Animation > Animator).

The various ways an Animator Controller can be created:

  • From the Project ViewA view that shows the contents of your Assets folder (Project tab) More info
    See in Glossary
    by selecting ‘Create > Animator Controller’.

  • By right-clicking in the Project View and selecting ‘Create > Animator Controller’.

  • From the Assets menu by selecting ‘Assets > Create > Animator Controller’.

This creates a .controller asset on disk. In the Project Browser window the icon will look like:

Animator Controller asset on disk
Animator Controller asset on disk

Animator Window

After the state machineThe set of states in an Animator Controller that a character or animated GameObject can be in, along with a set of transitions between those states and a variable to remember the current state. The states available will depend on the type of gameplay, but typical states include things like idling, walking, running and jumping. More info
See in Glossary
setup has been made, you can drop the controller onto the Animator componentA component on a model that animates that model using the Animation system. The component has a reference to an Animator Controller asset that controls the animation. More info
See in Glossary
of any character with an AvatarAn interface for retargeting animation from one rig to another. More info
See in Glossary
in the Hierarchy View.

The Animator Controller window contains:

  • The Animation Layer Widget (top-left corner, see Animation LayersAn Animation Layer contains an Animation State Machine that controls animations of a model or part of it. An example of this is if you have a full-body layer for walking or jumping and a higher layer for upper-body motions such as throwing an object or shooting. The higher layers take precedence for the body parts they control. More info
    See in Glossary
    )
  • The Event Parameters Widget (top-left, see Animation ParametersUsed to communicate between scripting and the Animator Controller. Some parameters can be set in scripting and used by the controller, while other parameters are based on Custom Curves in Animation Clips and can be sampled using the scripting API. More info
    See in Glossary
    )
  • The visualization of the State Machine itself.
The Animator Controller Window
The Animator Controller Window

Note that the Animator Controller Window will always display the state machine from the most recently selected .controller asset, regardless of what sceneA Scene contains the environments and menus of your game. Think of each unique Scene file as a unique level. In each Scene, you place your environments, obstacles, and decorations, essentially designing and building your game in pieces. More info
See in Glossary
is currently loaded.

Animator Controller
Animation States
Copyright © 2023 Unity Technologies
优美缔软件(上海)有限公司 版权所有
"Unity"、Unity 徽标及其他 Unity 商标是 Unity Technologies 或其附属机构在美国及其他地区的商标或注册商标。其他名称或品牌是其各自所有者的商标。
公安部备案号:
31010902002961