
Three-Axis
Animation:
The Hardships of Animating Three-Dimensional Characters in Real Time Games
By
JM Ringuet
Gamasutra
July
27 , 2001
URL: http://www.gamasutra.com/features/20010727/ringuet_01.htm
Introduction
3D game character animation is a relatively new craft where three dimensions in the game-world was not possible, even a few years back. Four years ago we would not have dreamed of animating facial expressions in real time, and now the latest line of video cards and consoles brings even more complexity to what we can do. I think it is the right time to start reflecting on 3D game animation as a craft by defining the methods we are using, establish some rules, find tricks, and understand what it takes to be a game animator. It is time to go from tinkering to crafting.
This article deals with the real time in-game character animation. I explain and discuss the very basic rules of what I call three-axis animation. However, it is also useful to many people who are involved with animation. I present the essence of what I have learned during the past few years. Every animator has a different approach to the same problems, but I feel my experience could be helpful to some of you, especially if you are totally new to in-game animation.
What's the big deal?
You probably remember
the little sixteen by sixteen blocks of pixels creating sprites that were supposed
to look and act like characters with personality in a 2D game environment. Moving
pixels around in 2D animation involves creating a blurry illusion of something,
while animating in 3D is close to reproducing an actual motion with all its
cold mathematical strangeness: acceleration, deceleration, forces, dynamics,
weights and curves. Going 3D is a huge and frightening step forward. For a 2D
animator, it's a strange new world. I started, like everybody else, using the
2D method of defining a few extreme key frames from a side view and hoping it
would work. Unfortunately, it did not work, mainly because 2D is an illusion
in an impossible flat world and is accepted by the player (your average Joe
player) as an illusion. In contrast, 3D implies a world that obeys the same
laws as ours, in a world that is truly believable. Sure Mario can hop and jump
without even moving his legs in a flat universe, but in a world with dimensions
and space, everybody expects him to act and react according to physical laws.
The difference between 2D and 3D is not an added dimension, but a heightened
expectation from the player. That's the big deal!
Now, as animators, we can ignore this fact, and still try to fix some little animations, or we can rethink our ways of animating from the ground up. That means leaving behind everything we learned from 2D, and understanding exactly what we are doing.
Gravity is the key
Let me define
the technical basics of what 3D animation exactly is. As I said earlier, in
a believable universe we have to consider laws of nature. The main law that
directly affects any movement in a believable universe is gravity. Every motion
in a 3D space either is created by gravity or is a reaction to gravity. For
example, you are probably sitting while reading this article. Try to stand up
and visualize what keeps you standing. Mostly, it is the muscles in your legs
(especially the thighs), and possibly the muscles in your arms if you are using
the table to lift you up, that produce a force strong enough to counterbalance
the effect of gravity. The creation of a force is the basis for motion in a
3Dspace.
However dry this
topic may sound, bear with me, because understanding the basics often makes
the difference between good and bad animations. If you keep in mind that your
character has to create a force to counterbalance the effects of gravity every
time you want to move it, you will avoid many of the common mistakes.
What does it really
mean? A quick example can illustrate my point. If you want to have a standing
character going from point A to point B, you have two ways of solving the problem:
In the first solution, you are creating the illusion of movement. The second solution means you are understanding and reproducing the way physical laws create a movement. Some people will disagree with this because it makes inverse kinematics invalid. The truth is, inverse kinematics is a bit of a monster. Making a character walk by moving its feet is wrong; it is the total opposite of a natural walk to imply that the feet are moving because the legs are moving. Rather, it is simulating a motion, instead of reproducing a motion, and trying to create an effect without knowing what forces produce it. You should be only interested in knowing what make things move, because if you understand what you do, you can control it.
Gravity, and how it is used to create movement, is the first rule of three-axis animation. The two other rules are balance, tilt and twist. Let me explain to you how those rules are tied together and can be used to create a complex animation.
Out of balance
I already said
that every motion is related to gravity and, in a way, created by it. Actually,
it is known as being in balance or out of balance. Almost every move starts
by putting the body out of balance and ends by regaining balance before falling
down. To explain this, let me try to define two very important concepts: the
center of gravity, and the idea of balance.
The center of gravity is a point situated between the hips (higher or lower
depending of the body mass). This center of gravity is usually the first bone
or root point of a character skeleton. To move the body, the limbs have to move
the position of the center of gravity.
A body is in balance when you can trace a vertical line from the pit of the neck (upper torso), the ankle of the supporting foot (if the character is supporting his weight on one leg), or to a line that joins the two ankles (if the character is supporting his weight equally with his two legs). If this line is not perfectly vertical, the body is out of balance. You will notice that the center of gravity can be positioned anywhere in relation to that line. The only important points are the pit of the neck and the ankles. The amount of unbalance is relative to the angle of the line. The body is more likely to fall if the angle between the body and the ground is increased.
![]() |
|
A
body is in balance when you can trace a vertical line
from the pit of the neck, the ankle of the supporting foot, or to a line that joins the two ankles. |
The human walk
is a great example to illustrate these two concepts and show how they are related.When
starting from a standing position, (assuming our subject is right handed) the
first movement of the walk is the forward rotation of the right leg around the
hipbone, lifting the right foot up in front of the body. At the same time, the
left leg rotates around the knee (the thigh is almost locked in place, the calf
muscles produce all the force), and the left foot follows by rotating around
the ankle. The body pushes forward as a result of the left leg rotation, and
since the right foot is not in contact with the ground at that moment, the center
of gravity is displaced. The whole body moves forward. This forward movement
suddenly stops when the center of gravity passes in front of the supporting
left leg (the balance line is not vertical anymore). The body becomes totally
out of balance and falls forward. This is when the right leg makes contact with
the ground, and becomes the supporting leg and stops the fall. The body continues
its forward motion. The whole movement repeats, however, this time the right
leg is producing the forward thrust and the left leg is lifting to catch the
fall. A walk is a succession of pushes and near falls, putting the body alternatively
out of balance and in balance. We are using the effects of gravity to move our
body mass on a linear path, with our legs simultaneously producing the thrust
force and support. A walk is a succession of controlled falls.
As you can see,
trying to animate a walk without knowing that you have to move the center of
gravity by putting the body out of balance is very difficult. If you do not
know why each part of the body moves, you cannot understand how they move.
The good news
is that there is an easy rule to remember: every movement of the body is based
on a thrust (from the calves, thighs, arms, etc.), moving the center of gravity
out of balance, and then a catch by a leg or an arm, putting the body back in
balance.
The amount of thrust and the time between the thrust and the catch determine the amplitude of the movement. Of course the more nimble the character is, the more extreme his movements will be. Moving a body means playing with gravity and playing with balance. If you remember that rule before starting any animation, you will have more control on what you can create.
Let's do the Twist
Now, there is
obviously more complexity in a motion than just using some muscles thrusting
a body forward in space and trying to avoid a fall. Why is movement so complex?
For the very simple reason that the body of every vertebrate is rigid. That
can sound strange if you consider all the stretching and moving muscles that
comprise most of our body, but the underlying structure is a rigid skeleton
made of solid bone. Even an insect has a solid exoskeleton that makes its body
rigid. Gravity, the most basic law of nature, has created the need for a rigid
structure like the human skeleton.
Every movement
we make is a rotation of several rigid bones around articulations. As far as
game animation is concerned, there is no flexibility whatsoever in the skeleton.
This is why you can animate a stick figure and still create a valid animation.
Muscles are built over the skeleton, and their only function is to create the
rotation of the rigid parts. Muscles create the force. Evolving big muscles
has always been difficult for any living being, because it is a complex and
very expensive piece of body hardware. Muscle also consumes a lot of energy
to function properly. This is why our bodies have just enough muscle to allow
us to move around. A simple increase in weight slows us tremendously. Animals
have a rigid skeleton, and because they do not have super powerful muscles,
they had to come up with strategies, called tilt and twist, to allow them to
move as fast as possible.
To illustrate
this, let me go back to the human walk example. We have seen that the first
movement of the walk is the forward rotation of the right leg around the hipbone,
lifting the right foot up in front of the body. Now if you stand up and try
doing this by only using your thigh muscles to move the leg forward, you will
quickly realize one thing, your foot is sliding on the ground. There is nothing
wrong with that, except that sliding a foot actually requires more effort than
lifting it up. You will also realize you are almost out of balance, and it is
difficult to stand straight.
So how can you actually lift your leg? You can do it only by tilting your hipbone to the left. Try again to move your leg by tilting the hips and you will understand that this is what you do naturally. The tilting of the hipbone has two effects. First, it makes your right leg higher than the left one, thus allowing rotation forward without having your foot scraping the ground. Second, it moves your center of gravity over your left leg (the vertical line drawn from the pit of the neck to the ground is moving from between your feet to your left foot). With the center of gravity over your left leg, you can lift your right leg and stay in balance. With one easy tilt, we create a solution to two problems. Of course, the balance is only on a lateral plane; we want to move forward. Therefore, the necessary unbalance I discussed earlier has to be created forward and not sideways.
![]() |
|
Tilting
your hipbone to the left makes your right leg higher
than the left one, thus allowing rotation forward without having your foot scraping the ground. |
Unfortunately,
the tilting of the hips produces a different unbalance between the upper and
lower parts of the body. Now that one leg is higher than the other, and the
body weight is moving to the left, we have to compensate that motion with the
top of our body. This is why we have to tilt our shoulders in the opposite direction
of the hips with the right shoulder will be higher than the left. Because this
unbalance is minor, the tilt of our shoulders is at a smaller angle than the
tilt of our hips. To stay level with the ground the head is also tilted slightly
in the opposite direction (same direction as the hips), as a side effect of
the shoulders tilting.
As you can see,
this very simple first step in the walk suddenly puts in motion not only the
legs, but also the hips, shoulders, spine, and the head. What may appear very
simple in a 3D program (just rotate one object around one pivot point), actually
requires rotations on many other parts of the skeleton. By understanding that,
you start to understand the underlying principle of three-axis animation: every
part of the body has to move in three dimensions to create a realistic movement.
Tilting is a very
effective and cost efficient way (in term of energy) to quickly rotate the parts
of a skeleton, but living in a three-dimensional universe allows us to improve
this efficiency with twisting. We have seen how the process of lifting our right
leg for this crucial first step involves a rotation forward (Z-axis rotation)
and the tilting of the hips (X-axis rotation). What about the Y-axis rotation?
When we move our right leg forward, we can easily improve the reach of the first step by simply rotating the hips on the Y-axis, twisting the lower part of the body to move the right hip forward. This is a very simple and small motion, but being at the top of the rotating leg, it gives a significant increase in reach. As in tilting, the same unbalance occurs with the top of the body. We have to twist the shoulders in the opposite direction of the hips to keep the body in balance. The head will also have to twist a little in the same direction as the hips.
![]() |
|
The
twisting motions of the body are designed to give
more amplitude to any motion, while at the same time being very cost effective in terms of energy. |
The twisting motions
of the body are designed to give more amplitude to any motion, while at the
same time being very cost effective in terms of energy. In addition, you discover
that a number of movements are being improved in reach and ease by subtle twists
at the main articulations (hips, thighs, shoulders and spine bones). The amount
of twisting in a body is only limited by the physiology of a living creature.
For example, lizards and crocodiles have a very flexible spine, which allow
them to twist in an extreme way to give more reach to their short legs. In humans,
females have wider hipbones, which allows them a lot more twisting and tilting.
To understand how an animal moves, you have to know the structure of the skeleton
and where the main muscles are located. With a little training, and by simply
observing a skeleton, you should be able to figure out the way a creature moves
(especially if you want to animate dinosaurs, aliens and weird creatures).
Tilting and Twisting are the last rule you have to understand to create any kind of animation. It means that every part of the body involved in creating a motion has to rotate on the three axes (X, Y, Z) at the same time. Because of gravity and the need to stay in balance, we vertebrates, have evolved this way of moving by rotating, tilting and twisting our rigid skeleton in the most efficient manner. Evolution plays a huge role in our movement. Centuries of trial and error have shaped muscles and bones to allow them freedom of movement and efficient management of energy. Learn this and understand it. Animations should not be random, because there is an underlying order and explanation for every part of a movement.
Creating
One of the best
features in the rules of three-axis animation is their universality. Every vertebrate
moves according to those rules, even the ones without legs (like snakes).
For example, as a dog runs, it moves its center of gravity forward by pushing
on its back legs (where its most powerful muscles are), slightly tilting the
hips and shoulders but twisting them to cover more distance. This exaggerated
twisting explains why the front paws of a dog hit the ground one after another
instead of at the same time.
![]() |
|
As
a dog runs, it moves its center of gravity forward
by pushing on its back legs, slightly tilting the hips and shoulders but twisting them to cover more distance. |
A monkey jumping
from branch to branch observes the same rules. Obviously, it uses only its arms
to move, but its arm muscles are not powerful enough to move fast, so it has
to use a combination of extreme tilting and twisting in the shoulders to cover
more distance with minimum effort.
How do I know
that? I didn't spend hours observing dogs or chimps in their natural habitat.
I simply tried to understand why they move in that way and what was the most
efficient way of moving. The three axis animation principles are guidelines
to analyze any kind of motion.
Knowing that you can replicate about any movement by understanding it, gives
you the freedom to invent new ones. The true challenge for an animator is obviously
not to do a run cycle, but to come up with that crazy out of this world movement
that your producer needs for his new fighting game. Games are not always realistic
(not realistic as in cartoony), and you often need to create something bigger
than life (like in any good kung fu movie), so you will have to invent a lot
of moves. Inventing is challenging, but if you use the basic rules I talked
about, you can come up with something as fantastic as you can imagine and at
the same time keep it totally believable.
Rules are better
than tricks when you animate. Rules can be applied to any kind of animation.
Rules give you the basis to elaborate, create and give style to your work. Try
to keep them in mind, and your life as a game animator will be a lot easier.
It's just a game
Now we have all
the tools necessary to create the right animation for our character, but we
have one last obstacle: remembering it's a game. Animating for a game requires
restrictions. From the number of polygons the character is made of, the ridiculously
limited number of bones you can animate, to the numbers of key frames you are
allowed for each movement. Restrictions are the ugly reality of game animation.
If I tell you to animate a guy hitting the perfect hook on the jaw of his opponent,
you will probably have no difficulty figuring it out. Now if I you to animate
it in twelve frames (almost a third of a second), you start to realize what
the real challenge is. There is no easy way to deal with restrictions in games,
however, a few guidelines are useful. If you keep in mind the basic rules of
three-axis animation, you can easily tweak, adapt, and simplify your animations
without changing them.
The most important
thing to keep in mind is how your animations will be seen, and not how they
look. Seeing an animation in a 3D program is very different from seeing it in
a game. This may seem obvious, but it is too often forgotten. If you are working
on a fighting game for example, the camera will be very close and probably always
on the side of your character. If you are working on a first person shooter,
chances are the only thing the player will really see, are the death animations
of his enemies. If you are working on a strategy title, the overhead camera
will flatten and change every animation. This means you have to look at all
of your animations from the perspective of the player. Try to place the camera
at the same angle as the game camera. Do not play your animations in slow motion
or frame by frame. Think of it as a whole rather than getting lost in useless
details and minute tweaks that nobody but you can see. Game animation is an
illusion and a craft, not a science.
The first thing
about an animation is making it right. The second thing to remember is to make
it interesting. This is why you have to know what part of your animation will
be seen in the game. Put the subtle details in place, the key frames and the
nicely crafted weight effects where you are sure they will be seen. Remember,
if the player can't see them, they do not exist, and all of your work has been
a complete waste of time
Try to make your
animations simple and expressive. Making it right, does not mean you have to
make it complex. One thing the basic rules of movement tell us, is that every
motion has to be cost efficient. Try to do the same for each animation. Do not
create key frames all over the place, because you will have to correct every
little glitch. Keeping it clean and simple will make it easier to manage.
Finally, basic
rules give you basic animations. Remember, that the rules of three-axis animations
are only a foundation to create, experiment, and discover. A memorable animation
is one that adds to the character. You have to understand the how in animation,
to be able to create the why. For instance, this guy is walking by thrusting
his legs, and tilting and twisting his hips and shoulders, but why does he want
to walk? What do I want to communicate with my animation? Just try to communicate
one simple feeling. The guy is a guard who is alone in a room, and is probably
bored and tired. Try to express the guys feeling of boredom through your animation.
The player will remember he saw a person who shuffled around and looked believably
bored, and not just a mindless robot. This will give the player a little more
information about the game world, and more enjoyment.
Rules are useful, and necessary, but they can become a distraction when the only thing you want is the right animation. Do not get obsessed with what is necessary to make it perfect. You should thrive for the good animation. An animation imbued with emotion that gives life to a mathematical object made of polygons.
Conclusion
The rules of three-axis animation are a simple way of understanding how a body
moves, fights and uses gravity to stay in balance, tilting and twisting its
limbs to achieve the greatest possible range with ease with each moving part
of a skeleton rotating on the three axes at the same time to help create the
motion. These rules are a base that allows greater control and freedom to create.
Try to learn them, understand them, and then forget them.
If you want more information, you can read the following books:
Bridgman's Life Drawing by George B. Bridgman - Dover
The Human Figure in Motion by Eadweard Muybridge - Dover
Cyclopedia Anatomicae by Gyorgy Feher - Black Dog & Leventhal Publishers
The Illusion of Life by Frank Thomas and Ollie Johnston - Hyperion
http://www.gamasutra.com/features/20010727/ringuet_01.htm
Copyright © 2003 CMP Media Inc. All rights reserved.