Hello i made a simple menu with tweenmax, but is not working fine, this is the code:
stop();
import com.greensock.*;
import com.greensock.easing.*;
import flash.events.MouseEvent;
var timeline:TimelineMax= new TimelineMax({paused:true});
var timeline2:TimelineMax= new TimelineMax({paused:true});
timeline.append(TweenMax.to(container, 3, {x:0, y:-1000, rotation:0, scaleX:1, scaleY:1}));
timeline.append(TweenMax.to((container.nos.fondo), 5, {alpha:.6}));
timeline2.append(TweenMax.to(container, 3, {x:1550, y:-1000, rotation:90, scaleX:1, scaleY:1}));
timeline2.append(TweenMax.to((container.des.fondo), 5, {alpha:.6}));
nos.addEventListener(MouseEvent.CLICK, go);
function go(e:MouseEvent):void {
timeline2.reverse();
timeline.play();
}
des.addEventListener(MouseEvent.CLICK, go2);
function go2(e:MouseEvent):void {
timeline.reverse();
timeline2.play();
}
sample into the file
Thank you