using timer

Find quick help here to get you started with Hollywood
zylesea
Posts: 227
Joined: Tue Feb 16, 2010 12:50 am
Location: Westfalen/Germany
Contact:

Re: using timer

Post by zylesea »

stefff285 wrote:hello my dear bugala how are you

ys i simply would like to display some 30 or more images as this

starttimer(1, 400)
displaybrush(1, 0, 0)
stoptimer(1)
starttimer(2, 400)
displaybrush(2, 0, 0)

and so on

thanx a lot

stéphane
If you just want to bluntly wait why not use wait(). For simple waiting things it's the most easy thing. Downside: during the waiting you cannot process other thing.

Code: Select all

displaybrush(1, 0, 0)
wait(20) ;waits 400ms
displaybrush(2, 0, 0)
wait(20) ;waits 400ms
(...)
displaybrush(n, 0, 0)

AFAIK know your syntax is wrong anyway. I think it should be:

Code: Select all

starttimer(n)
displaybrush(1, 0, 0)
waittimer(n,time) ;time=your waiting time in ms
stoptimer()
And if using timers, I wouldn't not start a new timer for every process, you can reset the timer if needed. But if you don't want to do something while waiting wait() is by far the easier way, timers are mostly good for waiting a certain ammount of time _while_ doing somethimg else or to stopmeasure time elapsed between some events.
User avatar
stefff285
Posts: 230
Joined: Sat Mar 03, 2012 12:59 pm
Location: dijon / france
Contact:

Re: using timer

Post by stefff285 »

hello zylesia ! yes i go try your second solution because a .mod will be played at the same time
thanx a lot

stéphane
User avatar
stefff285
Posts: 230
Joined: Sat Mar 03, 2012 12:59 pm
Location: dijon / france
Contact:

Re: using timer

Post by stefff285 »

ok i'm back yes
wait(100) is good ! the .mod can be played at the same time

thanx a lot
Post Reply