0
嗨,大家需要一些帮助。基本上我想在(guy1)击中hitTestObject(home1_mc)后前进到第4帧。Flash AS3用hitTestObject前进到下一帧
这是错误我得到:
ArgumentError: Error #2025: The supplied DisplayObject must be a child of the caller.
at flash.display::DisplayObjectContainer/removeChild()
at DNAGames2_fla::MainTimeline/exitFrameHandler()
ArgumentError: Error #2025: The supplied DisplayObject must be a child of the caller.
at flash.display::DisplayObjectContainer/removeChild()
at DNAGames2_fla::MainTimeline/exitFrameHandler()
这是我的代码:
function exitFrameHandler(event:Event):void{
if(guy1.hitTestObject(home1_mc)) {
removeChild(guy1);
removeChild(guy2);
removeChild(guy3);
removeChild(o1);
removeChild(cherry1);
gotoAndStop(4);
}
}
我都试图消除孩子的原因是因为他们仍然在屏幕后,我切换菜单为我的游戏。任何帮助表示赞赏
谢谢,所有提前它,看看它是否工作。这是为了我几天前的表态,但不知道更多; l) – Rickysteven1990