Game Development Reference
In-Depth Information
Repeat these steps to configure two other animations you'll use in this example: DefaultAvatar@
WalkForward_NtrlFaceFwd.fbx , and DefaultAvatar@WalkForwardTurnRight_NtrlWide.fbx . For the
second one, select Animations ➤ DefaultAvatar@WalkForwardTurnRight_NtrlWide to find both
WalkRightWide and WalkLeftWide Clips in the Inspector (Figure 5-38 ).
Figure 5-38. WalkRightWide and WalkLeftWide animation clips in the Project panel
If you select WalkLeftWide, then scroll down in the Inspector, you'll see that the Mirror box is
checked. This clip is a mirror reflection of WalkRightWide, a nifty property that saves you from
needing another set of .fbx files. If you are creating your own animation clips for a game, the mirror
property can save you a lot of time and effort for creating two symmetrical animations from a single
animation clip.
Now that the animations you need are configured, go back to the DefaultAvatar@Idle_Neutral icon
in the Project panel. Expand it by clicking on the arrow to display the Idle animation clip. With the
Idle animation clip selected in the Project panel, you can preview by playing it in the bottom of the
Inspector. Drag the animation clip icon from the Project panel to the Animator window, then drop it.
It should now be the orange default state for the controller.
In the same fashion, locate and expand the DefaultAvatar@WalkForward_NtrlFaceFwd animation to
display the Walk animation clip. Drag and drop it into the Animator window. Since Idle is already the
default animation state, the Walk state will appear as a gray box. You could change it to the default
state by right-clicking and selecting Set As Default from the context menu that appears, but leave it
as is for now.
You now have the Idle state and the Walk state. To create a transition between the two, right-click
the Idle state and select Make Transition from the context menu that appears. Now if you move the
mouse cursor around the window, it will drag a white arrow extending from the Idle state. Click the
Walk state to set the transition. Click the white arrow and it should turn blue while displaying its
properties in the Inspector (Figure 5-39 ). You set the conditions for changing from one animation
state to another with the transition properties. The Atomic property is checked by default, which
means the animation clip cannot be interrupted. Leave it checked.
 
Search WWH ::




Custom Search