How do i do timing and waiting without having to figure out my frame rate and then tween everything to it?
How would I wait in seconds? Do I have to get the time, save that to a variable, then once it’s, for example, 3 seconds later, something set to work 3 seconds later will start?
myTime = new Date();
startTime = myTime.getSeconds();
endTimer = myTime.getSeconds();
onPress = function () {
delay = 3;
a = startTime;
b = endTime + delay
if (a == b) {
trace (“it’s been " + delay + " seconds!”);
}
}
would that work?