Game Development Reference
In-Depth Information
Different objects have a different resistance to being deformed and a different
tendency to return to their original shape. Combined together the two tendencies
give an object its characteristic bounce. A rubber ball can be easily deformed but
has a high tendency to return to its original shape, so it bounces well. A stone has a
high tendency to return to its original shape but has a very high resistance to being
deformed: it will bounce, but not very much. A lump of clay will have a low resistance
to being deformed and no tendency to return to its original shape: it will not bounce
at all.
The force that resists the deformation causes the objects to stop colliding: their ve-
locities are reduced until they are no longer moving together. At this point the objects
are at their most compressed. If there is a tendency to return to their original shape,
then the force begins to accelerate them apart until they are no longer deformed. At
this point the objects are typically moving apart.
All this happens in the smallest fraction of a second, and for reasonably stiff ob-
jects (such as two pool balls) the compression distances are tiny fractions of a mil-
limeter. In almost all cases the deformation cannot be seen with the naked eye; it is
too small and over too quickly. From our perspective we simply see the two objects
collide and instantly bounce apart.
I have stressed what is happening at the minute level because it makes the math-
ematics more logical. It would be impractical for us to simulate the bounce in detail,
however. The compression forces are far too stiff, and as we've seen with stiff springs,
the results would be disastrous.
In chapter 7 we saw that two point objects will bounce apart at a velocity that is
a fixed multiple of their closing velocity immediately before the impact. To simulate
this we instantly change the velocity of each object in the collision. The change in
velocity is called an “impulse.”
14.1.1
I MPULSIVE T ORQUE
Now that we are dealing with rotating rigid bodies, things are a little more difficult. If
you bounce an object that is spinning on the ground, you will notice that the object
not only starts to move back upward, but its angular velocity will normally change
too.
It is not enough to apply the collision equations from chapter 7 because they only
take into account linear motion. We need to understand how the collision affects both
linear and angular velocities.
Figure 14.1 shows a long rod being spun into the ground (we'll come back to col-
lisions between two moving objects in a moment). Let's look closely at what would
happen in the real world at the moment of collision. The second part of the figure
shows the deformation of the object at the point of collision. This causes a compres-
sion force to push in the direction shown.
Looking at D'Alembert's principle in chapter 10 we saw that any force acting on
an object generates both linear and angular acceleration. The linear component is
Search Nedrilad ::




Custom Search