问题当我鼠标悬停或鼠标移出时使用动作脚本3到我的按钮它继续重复而不是完成动画或更糟糕的动画或对象没有显示。如果你将鼠标按下鼠标或鼠标移开,我已经在标签上添加了动画所在的标签,我也提出了停止动作
这是我的代码
stop();
import flash.events.Event;
btn1_mc.addEventListener(MouseEvent.MOUSE_OVER, casinoHome);
function casinoHome (e:MouseEvent):void{
MovieClip(this.root).btn1_mc.gotoAndPlay("rover");
MovieClip(this.root).outline1_mc.gotoAndPlay("roveroutline");
}
btn1_mc.addEventListener(MouseEvent.MOUSE_OUT, casinoHome2);
function casinoHome2 (e:MouseEvent):void{
MovieClip(this.root).btn1_mc.gotoAndPlay("mouseout");
MovieClip(this.root).outline1_mc.gotoAndPlay("mouseoutine");
}
btn2_mc.addEventListener(MouseEvent.MOUSE_OVER, sportsHome);
function sportsHome (e:MouseEvent):void{
MovieClip(this.root).btn2_mc.gotoAndPlay("rover2");
}
btn2_mc.addEventListener(MouseEvent.MOUSE_OUT, sportsHome2);
function sportsHome2 (e:MouseEvent):void{
MovieClip(this.root).btn2_mc.gotoAndPlay("mouseout2");
}
btn3_mc.addEventListener(MouseEvent.MOUSE_OVER, slotHome);
function slotHome (e:MouseEvent):void{
MovieClip(this.root).btn3_mc.gotoAndPlay("rover3");
}
btn3_mc.addEventListener(MouseEvent.MOUSE_OUT, slotHome2);
function slotHome2 (e:MouseEvent):void{
MovieClip(this.root).btn3_mc.gotoAndPlay("mouseout3");
}
答案 0 :(得分:0)
检查是否在每个动画结束时放置了stop();
动作。
示例:
btn1_mc:
outline1_mc: