通过从库中链接放置MovieClip的多个实例,是否有人知道如何在这些实例上应用hitTestObject?
我正在AS3中创建一个pacman风格的Flash游戏。如果有人知道可能有用的好教程,请随时告诉我。
答案 0 :(得分:0)
你可以使用这些功能
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