world
proc
GameHours()
while(global.GameInProgress)
global.hours--
global.time++
if(global.time==12)
if(global.AMPM=="AM")
global.AMPM="PM"
else
global.AMPM="AM"
if(global.time==13)
global.time=1
if(global.hours==0)
world.GameEnd()
return
world<<"<b><font color=red>It is [global.time]:00 [global.AMPM], there are currently [global.hours] hour(s) remaining until the games end.</font></b>"
sleep(100)
if(global.GameInProgress)
GameHours()
else
world<<"test"
return
Now here is the problem, even though it is a while(), it still goes through until the end. So, when the game ends, the sleep still goes. Then, it prints "test" because global.GameInProgress was set to 0. So, sometimes the first hour is very short because of this. Is there any way to externally end a separate proc?
Thank you in advance!