How to reset the wait timer subroutine thing?

Posted by Ada on Mon 27 Jun 2011 02:45 PM — 4 posts, 22,096 views.

#0
Hi! I was trying to use the "wait" module as described here:

http://www.gammon.com.au/forum/bbshowpost.php?bbsubject_id=4956

But I miscalculated the time I needed to wait between each command sent to the game so I hit Ctrl-Shift-R to reset the script. However, now I keep getting the error,

The timer (wait_timer_6145) subroutine named "wait.timer_resume" could not be found.

whenever I try to reset the script. Is there any way to get a 'clean slate' with this besides closing MUSHclient or the world entirely and restarting it? Thanks!

Love,
Ada
Netherlands #1
You can remove the timer from the Timers screen in your World Properties, if that is what you mean.

If I misunderstand you though, please clarify a bit more. :)
Australia Forum Administrator #2
Yes, the wait.time function basically adds a timer to the timer list. If you then reload the script the timer fires but can't find the script it is supposed to run. You could delete the timer if it is in the main world file.

This shouldn't be too much of an annoyance during testing. For production use, if you need to prematurely exit a "wait" loop, build in some sort of flag that gets tested in the loop.
#3
Ahh, yay! Never noticed a timer gets added. Thanks!