April 28th, 2002, 02:15 PM
Causing a delay in milliseconds
How do I cause the program to stop running for X amount of milliseconds?
Basically, I need a function that can pause the program. Couldn't find anything on Google or any books I have lying around.
April 29th, 2002, 02:11 AM
What platform are you programming on? I know that Sleep(...) works on Windows platforms.
I'm sure there is a similar function for Unix, but I don't know what headers (if any) you would need to include.
"Me fail English? That's unpossible!"
April 29th, 2002, 02:17 PM
If you are using unix, the function you're looking for is usleep, from unistd.h
usleep suspends execution for X microseconds.