Jump to content
Posted 12 August 2004 - 04:00 PM
Posted 12 August 2004 - 07:42 PM
Posted 12 August 2004 - 10:48 PM
void Sleep(float fSeconds)
float wakeTime = Ghoul.fTickTime + fSeconds;
while (Ghoul.fTickTime < wakeTime);
// Ghoul.fTickTime is the current engine time
Posted 13 August 2004 - 01:57 AM
asIScriptContext *ctx = GetActiveContext();
if( ctx )
Posted 13 August 2004 - 04:24 AM
Original post by WitchLord
Yes, you may call Suspend() from a system function called by the script. In fact, that is one of the reasons I made it.
You'll use the global function GetActiveContext() to get the script context that is currently running so that you can suspend it.