Wait command in c++??
hmmmm
i thought it was like this:
sleep( seconds )
and
Sleep( milliseconds ) <- needs windows.h
Could be wrong though
i thought it was like this:
sleep( seconds )
and
Sleep( milliseconds ) <- needs windows.h
Could be wrong though
I would suggest something like:
You can create other functions, if necessary, to make your code neater for
[ Google || Start Here || ACCU || MSDN || STL || GameCoding || BarrysWorld || E-Mail Me ]
#include <windows.h> // you must include windows.h to use Sleep()
inline void Wait(int seconds)
{
Sleep(seconds * 1000);
}
You can create other functions, if necessary, to make your code neater for
Sleep()
- for example:WaitSecs()
, WaitMins()
, WaitHrs()
, etc. [ Google || Start Here || ACCU || MSDN || STL || GameCoding || BarrysWorld || E-Mail Me ]
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement