Hi, I have created a menu with movieclips.
Right now, the rollover, rollouts and onClicks are working.
But…if you are OnClick, I don’t want the rollover state to still be active.
Any ideas?
Thanks!
function addMgListeners():void{
mg.addEventListener(MouseEvent.MOUSE_OVER, overAction, false, 0, true);
mg.addEventListener(MouseEvent.MOUSE_OUT, outAction, false, 0, true);
mg.addEventListener(MouseEvent.CLICK, clickAction, false, 0, true);
}
function overAction(event:MouseEvent):void {
TweenMax.to(event.target, .2, {tint:0x273555, ease:Back.easeIn});
}
function outAction(event:MouseEvent):void {
TweenMax.to(event.target, .6, {removeTint:true});
}
function clickAction(event:MouseEvent):void {
for(var b:uint = 0; b < mg.btnGroup.numChildren; b++){
var bb = mg.btnGroup.getChildAt(b);
TweenMax.to(bb, .3, {removeTint:true});
}
if(event.target.name != "btn2"){
menuName = event.target.name;
TweenMax.to(event.target, 1, {tint:0xcccccc});//n
TweenMax.to(boys, .6, {onComplete:loadPage, ease:Quad.easeInOut});
}
}