From the course: Unity 5: 3D Essential Training

Unlock this course with a free trial

Join today to access over 22,400 courses taught by industry experts.

Animating an object in Unity

Animating an object in Unity - Unity Tutorial

From the course: Unity 5: 3D Essential Training

Animating an object in Unity

- Unity has terrific animation tools natively, in addition to being able to import in animation from 3ds Max or Maya, for example. What I'm going to do is to animate my doors here in Unity, as they just need to slide open. I'll create animation files and map those two files, left and right doors, onto each of the door prefabs, reusing that animation. First, I'll go into my prefabs for doors. In here I need to get an animator controller created. I'll right click and choose Create and Animator Controller, naming this one Door A. Then I'll get that controller onto the door prefab, selecting it and dragging the controller over. And now I'll get a spherical trigger volume onto the door. I'll pull that door into my scene, press F to frame in, and get a spherical trigger going. There's a sound already on it, and I need to get a new component on it, choosing Add Component, Physics, and Sphere Collider. I'll take this spherical collider, move it over on the Z a little bit to be centered on the…

Contents