Game Development Reference
Hey, is that not enough for you? You're far from done yet! The Psaaj class also has many methods
that you can use to control the animation in exactly the same way you can control an animation in the
timeline. Table 10-4 shows methods you can use with your Psaaj objects.
Table 10-4. Tween class methods
Tween method name
What it does
Stops the animation at its current position.
Starts the animation from its beginning point.
Tells the animation to continue from its current position to a new finish
point with a new duration.
Takes two arguments: the new finish point and the new duration. You
could use it like this:
You can use _kjpejqaPk to alter the direction and duration of an anima-
tion after it has started.
Fast forwards the animation directly to the end.
Plays the previous frame in the animation.
Resumes the animation after it's been stopped using the opkl$% method.
If the animation is playing, rewinds it to the beginning and starts it playing
once more. If the animation has been stopped, the animation is rewound
to the beginning but not restarted.
Plays the animation back in reverse. It's usually used in conjunction with
the IKPEKJ[BEJEOD event from the PsaajArajp class.
You can use any of these methods the same way you use methods in other classes, like this:
I won't go into any of these properties or methods in any detail, but there's quite a treasure trove of
material here to keep a creative programmer busy for a long, long time. And you'll soon see that using
properties and methods from the Psaaj class is often easier and quicker than creating animations
manually on the timeline.