Register to post in forums, or Log in to your existing account
 

Play RetroMUD
Post new topic  Reply to topic     Home » Forums » zMUD General Discussion
Chris_3413
Novice


Joined: 22 Mar 2004
Posts: 46
Location: Australia

PostPosted: Mon Dec 13, 2004 3:19 am   

How do I Stop a runaway #Alarm trigger?
 
Help!, How do I Stop this? Question

I messed up a bit with an alarm trigger and forgot to put a + in front of the time and now its firing once a second forever and nothing i do seems to stop it.

this was in a little script i made for if i fell asleep forging and the alarm part looks somthing like this:
#alarm (10) {wake ; #alarm (1) {forge}}

what I wanted it to do was wait 10 seconds after falling asleep to wake up and then resume forging 1 second later i tired to do the right thing and use #alarm instead of #wait and now i'm stuck with an endless loop Sad
_________________
What do you mean, Fatal Error!
Reply with quote
Vorax
Apprentice


Joined: 29 Jun 2001
Posts: 198
Location: USA

PostPosted: Mon Dec 13, 2004 5:34 am   
 
#UNTRIGGER 1
That should get rid of the repeating alarm. Wash, rinse, repeat as necessary.
It sounds like you want something like this:
#ALARM +10 {wake;#ALARM +1 {forge}}
This will wait 10 seconds and send the 'wake' command and create the next alarm. 1 second later the 'forge' command will be sent. Each alarm is then deleted from memory.
_________________
Implementor at House of Ghouls
Telnet to House of Ghouls
Reply with quote
Larkin
Wizard


Joined: 25 Mar 2003
Posts: 1113
Location: USA

PostPosted: Mon Dec 13, 2004 4:09 pm   
 
I would recommend naming your alarms, for two reasons:

1. It gives you the ability to easily modify or delete the alarm with the name. If you have to use the timer pattern to remove it, how do you know you're not removing the wrong alarm?

2. It prevents you from creating hundreds of duplicate alarms when something loops in your scripts.

It sounds like what you might want here, though, is temporary triggers for when you wake up and when you are able to forge again. Not sure what MUD this script is for or what your output looks like, so maybe your alarms work just fine. Always helps to give more details when asking for help. Wink
Reply with quote
Kiasyn
Apprentice


Joined: 05 Dec 2004
Posts: 196
Location: New Zealand

PostPosted: Tue Dec 14, 2004 12:01 am   
 
i think what you need is

#trigger {You fall asleep} {wake;#alarm +1 {forge}}

replace 'You fall asleep' with whatever the mud sends you when you fall asleep :P
Reply with quote
Display posts from previous:   
Post new topic   Reply to topic     Home » Forums » zMUD General Discussion All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum

© 2009 Zugg Software. Hosted by Wolfpaw.net