Actionscript 3 Actionscript 3.0按钮不工作
这里是交易,这个动画,当点击添加Actionscript 3 Actionscript 3.0按钮不工作,actionscript-3,flash,adobe,Actionscript 3,Flash,Adobe,这里是交易,这个动画,当点击添加 what_mc 很好 但是如果我加上 whatanim_mc.case_mc 在它旁边,不再工作了。我没有错误。我该怎么办 what_mc.whatanim_mc.case_mc.addEventListener(MouseEvent.CLICK,WhatIsCase); function WhatIsCase(evt:Event):void { if(what_mc.currentFrame > targetFrame) stage.a
what_mc
很好
但是如果我加上
whatanim_mc.case_mc
在它旁边,不再工作了。我没有错误。我该怎么办
what_mc.whatanim_mc.case_mc.addEventListener(MouseEvent.CLICK,WhatIsCase);
function WhatIsCase(evt:Event):void
{
if(what_mc.currentFrame > targetFrame) stage.addEventListener
(Event.ENTER_FRAME,GoWhatIsCase);
}
function GoWhatIsCase(evt:Event):void {
intelmini_mc.prevFrame();
back_mc.prevFrame();
what_mc.prevFrame();
cross1_mc.play();
if(what_mc.currentFrame <= targetFrame) stage.removeEventListener
(Event.ENTER_FRAME,GoWhatIsCase);
}
感谢您的帮助:
谢谢大家! 什么是targetFrame?var targetFrame=1;每个动画有20帧。当一些被激活时,其他的会回滚。你不是指带有点的whatanim_mc.case_mc的实例名,是吗?