Hey there,
I am trying to have it so depending on what number of times the button has been pressed determines which transition to do. Can someone help fix my code for this to be possible.
code is:
ActionScript Code:
public function next1(event:MouseEvent):void
{
var counter:int = new int();
counter = 0;
if(counter == 1)
{
var nxt2_btn:Tween = new Tween(nxt1_btn, "x", Back.easeIn, 459.3, 940.3, 1, true);
nxt2_btn.addEventListener(TweenEvent.MOTION_FINISH, tranNextFrame);
trace(counter);
}
else
{
var nxt1_btn:Tween = new Tween(nxt1_btn, "x", Back.easeIn, 459.3, 940.3, 1, true);
gradChannel.stop();
nxt1_btn.addEventListener(TweenEvent.MOTION_FINISH, tranNextFrame);
counter = counter + 1;
}
Right now both transitions are the same, I know that but I am just trying to get the incrementing to work first.