Game Development Reference
After acceleration and friction happen, bouncing is a piece of cake (the un-infinite kind!).
Bind the ?]p symbol to the Lh]uan[>kqj_a class using the same steps you followed earlier. Move the
cat around the stage with the arrow keys and you'll notice that you can bounce it off the stage edges,
as shown in Figure 9-3.
Figure 9-3. Bounce the cat off the edges of the stage.
Double-click the Lh]uan[>kqj_a class in the Project panel to open it. You'll notice that it's remarkably
similar to Lh]uan[Bne_pekj, except for the addition of a new [^kqj_a variable and few other small
The [^kqj_a variable is declared with a value of ),*3: