Creating Animations

Let’s start building our animations for the player character. We will be creating the first few from scratch so that you can get a full understanding of how to create your own animations later on.

1. Find the Project files for Chapter 6 and load them in Unity.

2. In the _scenes folder, open the First_Animation Scene file to get started.

3. Select the Player GameObject from the Scene View or Hierarchy. Currently there are no animations assigned to it.

4. In the Inspector, click the Add Component button and select the Animation Component under the Miscellaneous section. Figure 6.2 shows the Animation Component with its default settings.

Figure 6.2 Our player character properties with the Animation Component added

Get Learning 2D Game Development with Unity®: A Hands-On Guide to Game Creation now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.