0
我想用按钮跳转到框架标签。他们跳到标签上很好,但再次按下时不会停下来。下面是我用来让按钮再次按下时休息的代码。保持放在框架标签上
getting_btn.addEventListener(MouseEvent.CLICK, gettingStarted);
function gettingStarted(evt:MouseEvent):void {
gotoAndPlay("ipad_in");
if (this.currentLabel == "ipad_rest"){
this.gotoAndStop("ipad_rest");
}
}
不知道我明白你想要做什么。在第一次点击时,您希望它转到标有“ipad_in”的帧,如果它已经在帧“ipad_in”上,然后转到帧“ipad_rest”,则第二次点击。这是你正在寻找的结果吗? – 2011-05-16 20:48:14
是的,我明白了。 Duh不得不翻动它们,所以它首先检查标签,然后去正确的帧标签。 函数getsStarted(evt:MouseEvent):void if(this.currentLabel ==“ipad_rest”) this.gotoAndStop(“ipad_rest”);其他 gotoAndPlay(“ipad_in”); } – cbeezy 2011-05-16 20:49:46