tags:

views:

24

answers:

1

By placing multiple instances of a MovieClip via linkage from the library, does anyone know how to apply hitTestObject on those instances?

I am creating a pacman style flash game in AS3. If anyone knows a good tutorial that might be helpful, feel free to let me know.

A: 

you can use these function

hitTestObject(obj:DisplayObject):Boolean
Evaluates the display object to see if it overlaps or intersects with the obj display object.


hitTestPoint(x:Number, y:Number, shapeFlag:Boolean = false):Boolean
Evaluates the display object to see if it overlaps or intersects with the point specified by the x and y parameters.

http://www.adobe.com/livedocs/flash/9.0/ActionScriptLangRefV3/flash/display/DisplayObject.html

Maged