Book Image

Unity Animation Essentials

By : Alan Thorn
Book Image

Unity Animation Essentials

By: Alan Thorn

Overview of this book

Table of Contents (14 chapters)
Unity Animation Essentials
About the Author
About the Reviewers

Animating multiple objects together

The camera fly-through animation created in the previous section involves animating only one object, namely the camera. But there'll be times when you'll need to animate multiple objects in sync, such as the wheels of a car rotating independently as the car moves forward. In this case, the car moves forward, but the wheels should also turn as they move with the rest of the car. To achieve this kind of multipart animation, you should first bring all relevant objects together under a single parent object. For the car example, all the wheels, the chassis, and engine will belong to a single parent, named Car.

Preparing a multipart object for animation


The sample car project is included in this book's companion files in the Chapter03/CarAnim folder.

When an animation clip is added to a parent object instead of a child object, you can animate channels on any (or all) of its children too, giving you control over multiple objects as far as the animation is concerned...