This content has been marked as final.
Show 1 reply
-
1. Re: Wait or hold
SeanWilson Oct 14, 2014 5:31 PM (in response to H.F. Duijndam)You have a couple of options.
The quick-and-dirty (and not recommended) solution is to tie up your processor doing nothing for 2 seconds:
tMillis = the milliseconds + 2000
repeat while the milliseconds < tMillis
nothing
end repeat
A better solution is to use a timeout object and a callback handler (I can't tell if the code you posted is in a behavior script attached to a sprite or in a movie script):
-- yadda yadda
t = timeout().new("goNext", 2000, #mNavigate, 0)
-- add this new handler to a movie script
on mNavigate padParameter, aTimeout
if ilk(aTimeout, #timeout) then aTimeout.forget()
go next
end

