views:

85

answers:

1

Hi,

I have 2 functions going in as3:

function blueDownBounce (e:MouseEvent):void {
    var blueDownY:Tween = new Tween(blue, "y", Regular.easeOut, -49, -19, 1, true);
}
blue.addEventListener(MouseEvent.MOUSE_OVER, blueDownBounce);

function blueUpBounce (e:MouseEvent):void {
    var blueUpY:Tween = new Tween(blue, "y", Bounce.easeOut, -19, -49, 1, true);
}
blue.addEventListener(MouseEvent.MOUSE_OUT, blueUpBounce);

I am trying to make it so that these functions are active after 3 seconds and they stay active for the whole time it is stopped on that frame after those 3 seconds. I know you have to make a timer and make it dependent on that timer but it wasn't working out well.

Thanks, Wade

A: 

The function needed to be defined above the timer and the event listener needed to be in the timer.

Wade D Ouellet