Chapter 11. Manipulating Information

The information that you store in variables, modify in expressions, and test with conditional statements often needs to be processed and manipulated by mathematical functions such as square roots, sines, cosines, and exponents. Flash can perform these calculations with the Math class, which lets you create formulas for complicated interactions between the objects in your movie and your viewer or for sophisticated physics in your motion. You can also turn to the Point class for help in geometry. Imagine modeling the correct trajectory of colliding objects to create a game of pool, simulating the effects of gravity for a physics tutorial, calculating probabilities for a card game, or generating random numbers ...

Get Flash CS4 Professional Advanced for Windows and Macintosh: Visual QuickPro Guide now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.