1 Reply Latest reply on Jun 25, 2010 3:43 AM by Kartik Mehta

    How to create delay before tween or function in AS?

    Graham vdR Level 1

      Hi there


      I have a number of cases where I have a tween happening in ActionScript, but I would like it to happen after a delay from the event that triggers it. At the moment I'm creating this delay by having a tween that does nothing (eg. an "_x" tween for which the start and end points are the same) and then using tween1.onMotionFinished = function(){… to create the one I really want.


      Is there a way to create this delay more neatly? At the moment what I am doing works fine, but it's still a workaround and if there's a better way to do it I'd like to learn. It'll probably help me out in the long term.


      I'm using AS2 in CS3.