Skip to main content

๐ŸŽž๏ธ Lesson 1.1: The Animation System: Clips, Animator & Controllers

Welcome to Unity Intermediate! We open with animation, the fastest way to make a game feel alive. Before you wire up a single state machine, you need a clear mental map of the pieces: the Animation Clip, the Animator Controller asset, and the Animator component. Get these three straight and everything in this module clicks into place.

๐ŸŽฏ Learning Objectives

By the end of this lesson, you will be able to:

  • Describe what an Animation Clip stores and where clips come from
  • Explain the job of the Animator Controller asset versus the Animator component
  • Trace how a clip flows all the way to a moving character on screen
  • Choose the right rig import type โ€” Generic vs. Humanoid โ€” and say what the Avatar is for
  • Set up the module's character and open its controller with confidence

Estimated Time: 35 minutes  ยท  Prerequisite: Unity Fundamentals (Editor, GameObjects & components, importing assets)

In This Lesson

The Big Picture: Three Pieces

Unity's animation system can feel like a lot of windows and assets at first. The trick is to realize it's only three moving parts that hand work to each other in a chain:

  1. Animation Clips โ€” the raw recorded motion (an Idle, a Run, a chest that opens).
  2. Animator Controller โ€” a project asset that organizes those clips into a state machine and decides which one plays.
  3. Animator โ€” a component you put on the GameObject that runs the controller and poses the model every frame.

Here is the whole pipeline in one picture. Read it left to right: several clips feed into one controller asset, the controller is assigned to an Animator component on your character, and the result is a model that moves.

The Unity animation pipeline A flow diagram. On the left, three Animation Clip cards (Idle, Run, Jump) point into a single Animator Controller asset in the middle. The controller points into an Animator component, drawn as a row in a GameObject Inspector. The Animator component points to a robot character on the right, which is now animated. Animation Clips Animator Controller (asset) Animator (component) Result โ–ถ Idle .anim clip โ–ถ Run .anim clip โ–ถ Jump .anim clip .controller Idle Run Jump ๐ŸŽ› Animator Controller RobotController โŠ™ Avatar animated character
Figure 1: The animation pipeline (faithfully recreated). Clips feed a Controller asset, which is assigned to an Animator component on the GameObject, which poses the model each frame.

๐Ÿ“– Definition

Asset vs. component: an asset lives in your Project window and is shared (the Animator Controller is one file many characters can reuse). A component lives on a specific GameObject in a scene (each character has its own Animator). Keeping this distinction clear is the single biggest "aha" of this module.

Animation Clips: Recorded Motion

An Animation Clip is a recording of how one or more properties change over time. Most often those properties are the rotations and positions of a character's bones, but a clip can animate anything โ€” a light's intensity, a material's colour, a door's hinge angle, even a script's public field.

Clips come from two places:

  • Imported with a model. When you drag in an .fbx character, its animations arrive as read-only clips nested under the model file in the Project window. This is how most humanoid motion (idle, walk, run) reaches your project.
  • Authored in Unity using the Animation window (Window โ–ธ Animation โ–ธ Animation). You record keyframes by hand โ€” perfect for a swinging platform, a UI pop, or a treasure chest lid.

Under the hood a clip is just a set of curves: one per animated property, with keyframes and interpolation between them. You will meet the curve editor properly in Lesson 1.4 when we add an Animation Event to a clip.

โœ… Pro Tip

Imported clips are read-only. To tweak one (change its length, loop it, or add an event), select the model in the Project window, open the Animation tab of the Import Settings, or duplicate the clip (Ctrl+D) into an editable copy first.

The Animator Controller Asset

One clip on its own can't decide when to play. That's the Animator Controller's job. It is a project asset (file extension .controller) that holds a state machine: a set of states โ€” each playing a clip or a blend of clips โ€” plus the transitions and parameters that move between them.

Create one with right-click in the Project window โ–ธ Create โ–ธ Animator Controller, then double-click it to open the Animator window and start dragging clips in. That window and its state machine are the whole subject of the next lesson, so here we'll just note what the controller is: the brain that chooses the current animation.

๐Ÿ’ก One controller, many characters. Because the controller is a shared asset, ten guards can all point their Animator components at the same GuardController. Each guard keeps its own live state (this one is running, that one is idling) while sharing the one set of rules. Edit the asset once and every guard updates.

โš ๏ธ Don't confuse the Animator Controller with the Animation window

The Animation window authors clips (keyframes on a timeline). The Animator window edits the controller (states and transitions). Two different windows, two different jobs โ€” Unity's near-identical names trip up almost everyone at first.

The Animator Component

The controller is just an asset sitting in your project until something runs it. That something is the Animator component. Add it to a GameObject (it's added automatically when you import a rigged model), drop your controller into its Controller field, and at runtime the component evaluates the state machine every frame and applies the resulting pose to the model.

Two fields on the component matter most:

  • Controller โ€” the .controller asset to run.
  • Avatar โ€” the description of this model's skeleton (more on this next). Empty for non-humanoid rigs.

From code you already know how to reach a component. Grabbing the Animator is no different, and it's how every gameplay script talks to the animation system:

using UnityEngine;

public class AnimatorIntro : MonoBehaviour
{
    Animator animator;

    void Awake()
    {
        // The Animator component is what actually plays the controller.
        animator = GetComponent<Animator>();
    }

    void Start()
    {
        // A quick sanity check you can delete later:
        Debug.Log($"Running controller: {animator.runtimeAnimatorController.name}");
    }
}

You won't set parameters yet โ€” that's Lesson 1.2 โ€” but notice the pattern: the component is the runtime handle. The clips and controller are data; the Animator is the engine that turns that data into movement.

Import Rigs: Generic, Humanoid & the Avatar

When you import a rigged model, Unity asks how to interpret its skeleton. You set this on the model's Rig tab in the Import Settings (Animation Type). There are three choices, but two matter day to day:

  • Generic โ€” Unity treats the skeleton as an arbitrary hierarchy of bones. Use it for anything not shaped like a person: a dog, a spider, a mechanical arm, a flag. Clips are tied to that exact skeleton.
  • Humanoid โ€” Unity maps the skeleton onto a standard human layout (hips, spine, two arms, two legs, a head). This unlocks animation retargeting: a walk recorded on one humanoid model plays on any other humanoid, even one with different proportions.
  • Legacy โ€” the old pre-Mecanim system. You'll almost never choose it for new work.

The magic behind Humanoid is the Avatar. It's a small asset Unity generates that says "this model's UpperArm bone is called mixamorig:LeftArm, its Hips bone is called Hips," and so on. Because every Humanoid model has an Avatar describing the same standard rig, Unity can translate motion from one to another.

The model Import Settings Rig tab A recreation of Unity's model Import Settings Inspector on the Rig tab. It shows an Animation Type dropdown set to Humanoid, an Avatar Definition dropdown set to Create From This Model, a Configure Avatar button, and Model, Rig, Animation tabs across the top. A small stick-figure Avatar preview shows a standard human bone map. Timmy.fbx (Import Settings) Model Rig Animation Materials Animation Type Humanoid โ–พ Avatar Definition Create From This Model โ–พ Skin Weights Standard (4 Bones) Configure Avatarโ€ฆ Revert Apply Avatar (bone map) green dots = mapped bones
Figure 2: The model Import Settings, Rig tab (faithfully recreated). Set Animation Type to Humanoid to generate an Avatar, whose bone map (right) lets one animation retarget to any humanoid.

โš ๏ธ Pick the rig type before you build

Humanoid clips and Generic clips are not interchangeable โ€” a controller built for one won't drive the other. Decide the Animation Type up front. If a downloaded character animates as a tangled mess, the usual culprit is the wrong rig type or a mis-configured Avatar. Reopen Configure Avatarโ€ฆ and check the bone mapping.

Setting Up the Module Character

Throughout Module 1 we'll animate Timmy, a rigged robot character. Unity ships a ready-made humanoid you can grab for free so you can follow along even without your own model:

  1. Open Window โ–ธ Package Manager, switch the dropdown to Unity Registry, and install Starter Assets - ThirdPerson (it includes a rigged character and animations). This is the same package we'll lean on for the real controller later in the module.
  2. Drag the character prefab into your scene. Because its model is imported as Humanoid, it already carries an Animator component with an Avatar assigned.
  3. Look at the Animator component in the Inspector: its Controller field points at an existing .controller asset. Double-click that asset to open the Animator window and peek at the state machine โ€” we'll dissect it next lesson.

That's the entire system on screen at once: imported clips, a controller asset organizing them, and an Animator component running it on Timmy.

flowchart LR C1["Animation Clips
(Idle, Walk, Runโ€ฆ)"] --> CTRL["Animator Controller
(.controller asset)"] CTRL --> ANIM["Animator component
(on Timmy)"] AV["Avatar
(bone map)"] --> ANIM ANIM --> OUT["Posed character
every frame"]

Figure 3: How the pieces connect โ€” clips and an Avatar feed the controller and component, which output a posed character.

Hands-on Challenge

๐Ÿ‹๏ธ Exercise 1: Trace the pipeline in a real project

Objective: Find all three pieces on a working character and confirm how they connect.

  1. Install Starter Assets - ThirdPerson from the Package Manager and drop its character into a scene.
  2. Select the character. In the Inspector, find the Animator component and note the asset in its Controller field.
  3. Double-click that controller to open the Animator window. You've now seen the asset the component runs.
  4. In the Project window, expand the character's .fbx and find the nested clips feeding that controller.
  5. Select the .fbx, open the Rig tab, and confirm Animation Type is Humanoid with an Avatar.
๐Ÿ’ก Hint: I don't see an Animator component

Make sure you dropped the character prefab into the scene, not just the raw model mesh. If you built the object yourself, add the component via Add Component โ–ธ Miscellaneous โ–ธ Animator and drag a controller into its Controller field.

โœ… Success check

You can point at the three pieces and say which is which: the clips under the FBX, the .controller asset in the Project, and the Animator component on the GameObject โ€” plus the Avatar on the Humanoid rig.

๐Ÿ‹๏ธ Exercise 2: Log the controller from code

Attach the AnimatorIntro script above to the character, press Play, and read the Console. You should see the name of the controller it's running โ€” proof your script reached the live Animator component. Bonus: use Add Component to put an Animator on an empty cube and watch how, with no controller assigned, the log line is empty.

๐ŸŽฏ Quick Quiz

Question 1: Which of these is a shared project asset rather than a per-GameObject component?

Question 2: What does choosing the Humanoid rig type give you that Generic does not?

Question 3: An Animation Clip fundamentally storesโ€ฆ

Summary

๐ŸŽ‰ Key Takeaways

  • Unity animation is three pieces: Clips โ†’ Controller (asset) โ†’ Animator (component) โ†’ posed character.
  • An Animation Clip is recorded curves; clips come from imported models or the Animation window.
  • The Animator Controller is a shared .controller asset holding the state machine that chooses the current clip.
  • The Animator component runs that controller on a specific GameObject and is your code's handle into the system.
  • Generic rigs are for non-human skeletons; Humanoid rigs generate an Avatar and unlock retargeting.
  • Don't confuse the Animation window (authors clips) with the Animator window (edits the controller).

๐Ÿš€ What's Next?

You now know the players and how they hand off to each other. In Lesson 1.2: States & Transitions we open the Animator window and build the state machine itself โ€” creating states from clips, wiring transitions, and driving them with parameters your code will flip.

๐ŸŽž๏ธ You have the map

Clips are the footage, the controller is the director, the Animator is the projector. Hold that picture and every animation window in Unity makes sense.