Dothis using either the Track View or Set Key buttons in the Motion panel.When working on an animation, define its range in the Time Configura-tion menu.. You can also define frame rate
Trang 1FIGURE 6.50 Adding a Time Tag gives you a nice shortcut to an animation clip.
Move your Time Slider to Frame 50 Click on the Add Time Tag box,and a new option is there for you to click on: 20 Idle Click on it, and theTime Slider automatically goes to the first frame of the idle (Figure 6.51)
FIGURE6.51 Time Tags will appear when
clicking on the Add Time Tag message box.
Since Widge will be used for a WildTangent export, you will need toknow the start and end time of the animation when you export the ani-mations later Bring up Time Configuration again, and change your EndTime to 60 instead of 59 Then go to the Time Tag menu and select EditTag (Figure 6.52)
FIGURE 6.52 Edit Time Tags to change
the name or delete a time tag.
When the Edit Time Tag menu pops up, select 20 Idle from the listand rename it in the Tag Name field to Idle Start Hit OK, and then go toFrame 60 Click on Add Time Tag again, and create a new time tag calledIdle End (Figure 6.53)
Trang 2Chapter 6 Keyframe Animation: Part 231
FIGURE 6.53 Add the end of the idle motion
to the Time Tag list.
The benefit of using time tags should be obvious They are definitely
most useful when a character has a substantially large number of
anima-tions With the animation complete, save your max file, skip ahead 20frames, and you're ready to move on to any other animations required Ifyou want or need to, load Widge4.max from the Chapter6 directory onthis book's CD-ROM (Figure 6.54)
FIGURE 6.54 Load Widge4.max to see how the alien psycho's supposed to look.
SUMMARY
Before animating, decide whether or not to use keyframes, motion ture, or a combination of the two Whichever method you choose, think
Trang 3cap-of your 3ds max file as an animation folder that holds all your character'smoves Prior to setting any keyframes, make sure you prepare your Bipedfor animation by assigning a transparent material to it and/or creating aNamed Selection Set out of it for quick selection.
Once you're ready to begin animating, start by saving Frame 0 in theBiped's default position, exactly as it was when attached to the mesh Dothis using either the Track View or Set Key buttons in the Motion panel.When working on an animation, define its range in the Time Configura-tion menu You can also define frame rate and playback speed there.Copy keyframes either in the Track View or via the Time Slider bar, butalways keep a buffer between animation clips for easy identification.Learn the effects of the tension, continuity, and bias settings of the de-fault TCB animation controller Use them to create smooth loops for youranimation clips Always strive for secondary motion to add that extra bit
of detail to your animation Use Layers to add this sort of additional
mo-tion over the rest of an animamo-tion.
Finally, make navigation through your collected animations (youranimation folder) easier by adding time tags to the start and end points ofyour various motion clips
Trang 4KEYFRAME ANIMATION:
PART II
233
Trang 5You now have the fundamentals mastered for using 3ds max and
character studio to create keyframe animations, but Widge was justyour appetizer As an enemy character for a game, he has a rela-
tively less demanding animation set and mainly plays the role of target.
He sits idle, runs, walks, attacks, reacts to being attacked, and dies ure 7.1)
(Fig-This isn't such a lengthy list; the player character, on the other hand,
is a much more demanding type of real-time game entity
FIGURE 7.1 Widge only has the most basic animation set because it's all he needs.
BETTY'S ANIMATIONS
Betty Bad is and isn't a "typical" real-time character At 2,000 polygonsand with WildTangent's dynamic LOD code, she has a medium to lowpoly-count, yet she's in a third-person, online-only action game, using anatypical game engine: WildTangent's Web Driver technology She could
just as easily have been implemented in a Quake, Unreal, or LithTech
game engine as well Another of Betty's non-typical features is her lack ofaccess to a multitude of different weapons that magically appear and dis-appear on command She only has one weapon, which processes energyinto different forms of ammo
One Chick, One Gun
Despite not having to change an arsenal of weapons, Betty still has ashotgun, grenade launcher, machine gun, rocket launcher, and railgun;
they're represented more by their effects than by a different physical
weapon The decision to use this approach addresses two issues common
to action shooter games: the magic backpack and the cumbersome task ofholding a weapon that obscures most of the character Taking away herability to carry around artillery consisting of a dozen different weaponsdoesn't hurt the gameplay mechanics It actually saves polygons while in-troducing the aforementioned alternate theory to the magical backpack: aweapons-manufacturing backpack Whenever Betty kills an enemy, itleaves behind energy for her to pick up and add to her weapons system
Trang 6Chapter 7 Keyframe Animation: Part II 235
backpack Along with this variant of a popular paradigm for the weapons,Betty also serves as a guinea pig for animation ideas that the game's de-signers wanted to try (but never did) in special move animations for
Quake III Arena (Q3A).
Special Moves
Like fighting games, action games in which characters have to run around
and shoot things can be spiced up a bit with combination moves, or special
moves These animations are triggered by the player hitting a couple of
keys simultaneously or by a condition met during the game, such as acharacter changing direction quickly So, in addition to the standard ani-mation set that a typical game character of this genre will have, Betty has
a few extras to support this special-move functionality She also has extraanimations due to the environment and the constraints of the game tech-nology Yet she still has the following standard animations: Idle, Run,Backpedal, Walk, Jump, Strafe, Shoot, Melee, Pain, and Death
She also has the use of Special Moves, Use Moves, Swimming, covery, and Angled animations
Re-As mentioned before, Betty has almost 3,000 frames of animations
and that's definitely not your average animation count It's due primarily
to the way her character had to be implemented and fit within the gametechnology It's also because the player sees her in the third-person per-spective Being on the screen all the time in a typical shorter animationset would get repetitive and uninteresting very quickly, but Betty has awide range of animations Betty also provides an excellent opportunityfor you to learn about animations similar to those you may be faced withwhen animating a game character of your own You'll create parts of heranimation set in this chapter by first concentrating on those motions thatare completely keyframed In the next chapter, you'll use motion capture
to create the remaining animations Let's begin by creating a couple ofidle animations
Betty needs three idle animations: left foot forward, right foot forward,and both feet even The reason for this is for variety, and so that her tran-sition from one animation to another is properly supported Creatingthese idles will also give you some idle pose ideas for animating your owncharacter Load Betty08.max from the Chapter7 directory on this book'sCD-ROM (Figure 7.2)
Trang 7FIGURE 7.2 Betty needs some idle moves.
It's All in the Pose
Since idle animations have to be relatively short loops that can't be too volved because of their receptiveness, they are mainly all about the pose.
in-Change your Time Configuration settings to a Start Time of 20 and anEnd Time of 50 Then, using your Rotate and Move transforms, poseBetty at Frame 20 so she looks like she does in Figure 7.3 Use the mainconstruction plane as a ground reference to keep her feet right on theirline
With her body turned slightly, her gun at the ready, her right handpoised for balance, and a lower center of gravity, Betty is alert and ready
to go Now you need to lock her feet and copy all the keyframes at Frame
20 to Frame 50 Do this by alternately selecting each foot and hitting theSet Planted Key button on the IK Key Info rollout menu Make sure to
uncheck the Join to Prev IK Key button (Figure 7.4).
Set Planted Key cannot be used on multiple limbs at the same time Select and set a key for one limb, and then repeat the process for any others.
In character studio, setting a planted key will automatically cause ared dot to appear on the selected limb, which indicates the active IK pivotpoint These points on the hands and feet not only give you better use of
Trang 8Chapter 7 Keyframe Animation: Part II 237
FIGURE 7.3 Make the idle pose interesting.
FIGURE 7.4 As soon as the pose is established, lock
the feet with the Set Planted Key button.
the IK chain that's established for the arms and legs, but can result insome interesting animations Select Betty L Foot and hit the Select Pivotbutton in the IK Key Info rollout menu to see all the available pivots forthe foot Change the active pivot by clicking on any of the dots that ap-pear on the foot with Select Pivot active
While you can change the pivot of an object at any time by using theSelect Pivot button, the hand or foot only rotates around that point ifthe limb has a Planted Key set Otherwise, it rotates from the normal for-ward kinematic pivot point
Trang 9FIGURE 7.5 With the Select Pivot button active, pick a new pivot point for the foot.
Turn Select Pivot off, open Track View, and copy all the keys atFrame 20 to Frame 50 Close or minimize Track View, and scrub the TimeSlider back and forth You will see a subtle motion because of the Conti-nuity setting of 25 for all keys, and the keys set at Frame 0
Anchor Keys
It's crucial that you lock down the feet at the beginning and end of theanimation so that you can animate Betty by having her perform a smallmotion in the middle of the animation segment While using Set PlantedKey is one great way to lock the feet, another way is to use Anchor Keys
in the Keyframing rollout menu (Figure 7.6)
To see how this method for locking the feet works, go back into TrackView and delete the key for Betty R Thigh at Frame 50 Close or minimizeTrack View, select the right foot, go to Frame 20, and hit the Set Free Keybutton in the IK Key Info rollout menu This turns the IK Blend to 0 and
puts the foot back in Body coordinate space, effectively unlocking the foot
(Figure 7.7)
Trang 10Chapter/ Keyframe Animation: Part II 239
FIGURE 7.6 You can also lock the feet down
using the Anchor Key buttons.
FIGURE 7.7 The Set Free Key button changes
the keyframe back to an unlocked key.
The red dot that was the pivot will go away; when scrubbing theTime Slider, you will see that the foot isn't planted Now, go to Frame 20and click the Anchor Right Leg button to make it active to lock the rightleg in place (Figure 7.8)
Click again on the Anchor Right Leg button to toggle it off, andFrame 20 becomes a planted key again for the right foot, changing the IKBlend to 1 and putting it back into Object space (Figure 7.9)
FIGURE 7.8 With Anchor Right Leg active, the
right foot is locked in place.
FIGURE 7.9 Keyframes for limbs are automatically converted to a planted key just by clicking on the Anchor button.
Regardless of the method you use, planting the feet is necessarywhen adding a small motion in the middle of the animation segment Butfirst, strip out the extra motion caused by the Continuity setting by goinginto the Track View, selecting a row of keys, right-clicking on one of the
Trang 11keys, and entering 0 for the Continuity value Repeat this for all tion tracks except Betty L Clavicle and Betty R Clavicle—change theirContinuity settings to 15 (Figure 7.10).
anima-FIGURE 7.10 Change the Continuity settings for all tracks to 0, except for the arms.
Close the Track View, then scrub the Time Slider to see the change inthe movement of all the Biped objects Next, make sure your Animatebutton is still active, select the COM (Betty), advance to Frame 35, anddrag it down about 0.6 units along the Z-axis Hit the slash ( / ) key or the
V key to play the animation and check how it looks (Figure 7.11).Change your Time Configuration to have an End Time of 50, and cre-ate Time Tags for the animation Call the first frame Idlel Start and thelast frame Idlel End (Figure 7.12)
Doubling Keys
While it's extremely useful to use your 3ds max file as an animationfolder to store the animation set of your character, the TCB controller cancause you some problems with all the extra motion that results from thedefault Continuity setting Instead of manually changing the Continuity
to 0 to get rid of this motion "drift," you can achieve the same results by
doubling the keys Use this technique, also called bracketing, for Betty's
Trang 12Chapter 7 Keyframe Animation: Part II 241
FIGURE 7.11 Betty is happily idling away.
FIGURE 7.12 Add Time Tags to the beginning and end of
the animation.
next idle animation First, change your animation range to have a StartTime of 70 and an End Time of 99 At Frame 70, pose Betty so she lookslike she does in Figure 7.13, with her right foot forward
Lock down the feet again, but this time use Track View to manuallyenter the IK Blend and to make the change to Object space Open TrackView, select the key at Frame 70 for Betty L Thigh, and right-click on it sothe keyframe parameters open; change IK Blend from 0 to 1 and changeBody to Object (Figure 7.14)
Trang 13FIGURE 7.13 This is Betty in her right-foot-forward idle pose.
FIGURE 7.14 Set the IK Blend to 1 and switch to Object space to lock the feet.
Do the same thing for Betty R Thigh, and then copy all the keys atFrame 70 to Frame 100 Minimize Track View and scrub the Time Sliderback and forth The excess animation is there Go back into Track Viewand copy the column of keys at Frame 70 to Frame 69 and to Frame 101(Figure 7.15)
Close Track View and scrub the Time Slider back and forth again—now there's no extra movement This "double-tap" bracketing tech-
Trang 14Chapter 7 Keyframe Animation: Part I 243
FIGURE 7.15 Doubling keys has the same effect as changing Continuity to 0.
nique strips out the effect of the animation curve of the Continuity ting, even though it's still set at 25 Without a space between keys, theanimation curve becomes non-existent and affects Continuity as if itwere set to 0
set-Now you need to give the character a slight animation like you didfor the first idle, just a subtle bouncing motion Do this by going to Frame
85, selecting COM (Betty), making sure Animate is active, and loweringthe Biped root object by 0.7 units along the Z-axis (Figure 7.16)
Secondary Motion
At Frame 85, select all the fingers of the right hand (but not the thumb),and rotate them along the Z-axis, to look as if Betty were slightly flexingher hand Curl the thumb downward and in slightly (Figure 7.17)
The quickest way to select only the fingers is to double-click on the Biped hand Then, holding down the Alt key, dick on the Hand and Thumb objects to deselect them.
Next, while still at Frame 85, select Betty L UpperArm and rotate itdown just 2 degrees along the Z-axis Now hit the Page Down key to se-lect the left forearm, advance to Frame 90, and rotate it about 3 degreesdownward, also along the Z-axis (Figure 7.18)
While at Frame 90, rotate Betty's head 3 degrees downward to giveher a slight head nod (Figure 7.19)
Trang 15FIGURE 7.16 Shifting the body down slightly while midway through the animation will
result in a motion that suggests impatient readiness.
FIGURE 7.17 Add secondary motion to the right hand by slightly flexing the fingers.