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
Belgarad
Novice


Joined: 11 Mar 2001
Posts: 37
Location: Canada

PostPosted: Wed May 29, 2002 11:23 pm   

Order of triggers
 
ok, i have a problem and i think it will have a very simple solution but i don't know what it is yet. I have a trigger for whenever i finish memorizing spells to auto stand. but i have another script i turn on and off that causes something else to happen when i finish memorizing but i need it to happen immediatley after the stand command and not before it. is there a way to give one priorioty?
Reply with quote
NiteTrip
Novice


Joined: 21 May 2002
Posts: 40
Location: Canada

PostPosted: Thu May 30, 2002 12:59 am   
 
Sure, just think of the logic differently

trigger it on the text the mud sends you when you stand up. ie. the mud sends
"You clamber to your feet" have it check for a dummy variable you set on the stand up trigger for memorization. so basically if the dummy variable is there and you just stood up, trigger whatever it is you do, then reset the dummy variable. Kinda like this:

#trigger {You have memorized the spell} {#var dummy 1;stand}
#trigger {You clamber to your feet} {#if (@dummy = 1) {next thing to do;#var dummy 0}}

OR I guess the way the mud parses things is line by line, so the easiest way would be this:

#trigger {you have memorized the spell} {stand;the next thing you do}

This will work provided that the next thing you do is a MUD command and not another zmud script, if it is a zmud script, the first way will work.
Reply with quote
Kjata
GURU


Joined: 10 Oct 2000
Posts: 4379
Location: USA

PostPosted: Thu May 30, 2002 1:52 pm   
 
Triggers are fired off in the order they appear in the settings editor. Just make sure that View|Sort By|None is selected and then drag and drop them to the position you like them.

Kjata
Reply with quote
Belgarad
Novice


Joined: 11 Mar 2001
Posts: 37
Location: Canada

PostPosted: Fri May 31, 2002 12:25 am   
 
One more thing about this kind of stuff. I have a set of variables i use for this script type thing but whenever i start it, it makes anotehr copy of all the variables in the main folder. how could i stop this?
Reply with quote
TonDiening
GURU


Joined: 26 Jul 2001
Posts: 1958
Location: Canada

PostPosted: Fri May 31, 2002 2:16 am   
 
If you are getting another copy of the variables it is probably due to the fact that
the other variables are disabled in a class folder.

zMud should find the variable if it is enabled anywhere in all the folders.

TonDiening
Beta Upgrading to 6.26
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