【发布时间】:2018-03-09 04:31:13
【问题描述】:
我有多个按钮可以加载多个影片剪辑。我的问题是,当一个加载时它不会消失,阻止其他人在单击按钮时加载。下面是我的代码。我需要添加和“if”语句吗?任何帮助将不胜感激。谢谢。
movieButton.addEventListener(MouseEvent.CLICK, gotoMovie);
webButton.addEventListener(MouseEvent.CLICK, gotoWeb);
mailButton.addEventListener(MouseEvent.CLICK, gotoMail);
function gotoMovie(event:Event):void {
var moviescene:MovieClip = new movie();
stage.addChild(moviescene);
}
function gotoWeb(event:Event):void {
var webscene:MovieClip = new web();
stage.addChild(webscene);
}
function gotoMail(event:Event):void {
var contactscene:MovieClip = new contact();
stage.addChild(contactscene);
}
【问题讨论】:
-
如果您标记您正在使用的语言会有所帮助。
-
哎呀!谢谢。
标签: actionscript-3 removechild addchild