Hit Testing
It can be useful when creating dynamic code based animation to be able to detect when one display object collides with another. This is called āHit Testingā. You can hit test two ways, with two objects or with an object and a point on the stage.
To hit test two objects, use the hitTestObject method:
object1.hitTestObject(object2)
To hit test and object and a point, use the hitTestPoint method:
object.hitTestPoint(xcoordinate,ycoordinate)
TWEENS
The Tween class allows you to animate the same properties you could using a Motion Tween on the timeline:
Now, with these objects, for the first time we are using Flash packages that are not automatically imported when we publish the file, so we have to do that first:
import fl.transitions.Tween; import fl.transitions.easing.*;
TRANSITIONS
There are a number of transitions designed to bring content on or off the stage in the fl.transitions package. The Transition Manager class allows you to access these transitions:
USING THIRD PARTY LIBRARIES: TWEEN LITE
Third part libraries are code created by companies or individuals to extend the capabilities of Flash or make common tasks easier. These libraries arenot part of the core actionscript packages but can be imported into your Flash project for use in your applications. Weāre going to look at one popular library today.
Tween LiteĀ ā A more robust tweening engine than the built in Tween class.
Here are theĀ detailed instructionsĀ that weāre going to follow today to use Tween Lite
There is also a good tutorial on importing third party librariesĀ here