Delays in ActionScript (Flash)? Alternatives to setInterval
- by yar
While setInterval is handy, it's kind of limiting. Every time I want to add a Tween I have to add a new method. I do not want to alter the structure of my code just to add in some delays. Isn't there any way to say this without making methods for A and B?
// do A
// wait N seconds
// do B
I don't want to use a while loop with Dates because I think it will be blocking. Isn't there anything like Thread.sleep in ActionScript?