Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

Newcomers DBPro Corner / Little help please (real basic stuff methinks)

Author
Message
Someone
20
Years of Service
User Offline
Joined: 22nd Feb 2004
Location: Australia
Posted: 1st Mar 2004 05:12
how do I get a timer working without it slowing down my main loop? I tried this, but it diddn't work.

.. Help please?

Call me Dean.
PC1: 2.0 Ghz AMD Athlon XP - 512 Meg DDR RAM - GeForce FX 5200, PC2: 0.5 Ghz P3 - 256 Meg SD RAM - GeForce2 MX 400, PC3: 2.5 Ghz P4 - 256 Meg DDR RAM - Integrated Video Card
Night Giant
21
Years of Service
User Offline
Joined: 26th Jul 2003
Location:
Posted: 1st Mar 2004 05:46
well, the fastest way (that i know of) is to use the timer() command. just save timer() to a variable once, and compare it to timer() every loop, i.e. if you stored timer() in a variable called time, then do timer()-time to figure out how many milliseconds it has been since you started the timer. to change it to seconds just to some simple division and change to an integer.

oh, wow. insignificantpunks.cjb.net. we like orange treble clef notes, just for future reference.

no: website for progs yet.

Login to post a reply

Server time is: 2024-09-22 00:14:01
Your offset time is: 2024-09-22 00:14:01