Thread: Script Halting
View Single Post
  #6  
Old 09-20-2005, 12:15 AM
ZeLpH_MyStiK ZeLpH_MyStiK is offline
Scripter
ZeLpH_MyStiK's Avatar
Join Date: May 2003
Location: NYC
Posts: 553
ZeLpH_MyStiK is on a distinguished road
Send a message via MSN to ZeLpH_MyStiK Send a message via Yahoo to ZeLpH_MyStiK
Quote:
Originally Posted by calani
horribly simple way of doing it based on one of the suggestions i posted earlier:

NPC Code:

function onTimeout() {
if (!this.scriptpaused) {
stuff();
}
setTimer(.1);
}

that doesn't pause the script calani, the timeout's still running.
in gs1:
if (created) {
this.running=1;
timeout=.05;
}
if (playerchats) {
if (strequals(#c,run)) {
this.active=1;
timeout=.05;
}elseif (strequals(#c,stop)) this.active=0;
}
if (timeout && this.active==1) {
//script
timeout=.05;
}
__________________
Reply With Quote