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

Play RetroMUD
Post new topic  Reply to topic     Home » Forums » CMUD General Discussion
Kalie
Beginner


Joined: 23 Jun 2008
Posts: 22

PostPosted: Mon Dec 08, 2008 1:37 am   

How do you turn off triggers which are contained in classes?
 
If I have a class named "akill" (say I'm using the simple combat bot) and that class has a trigger with an ID of "kill1" - how do I turn that trigger on or off with an alias/trigger outside of that class? Is that possible? I have no problems turning classes on or off and turning triggers on or off - but if the trigger is in a class - then I'm stuck. I'm sure there's a something simple I'm missing. Thanks guys.
Reply with quote
cazador
Apprentice


Joined: 08 Dec 2005
Posts: 108

PostPosted: Mon Dec 08, 2008 2:11 am   
 
#t- kill1 to turn it off
#t+ kill1 to turn it on
Reply with quote
Arde
Enchanter


Joined: 09 Sep 2007
Posts: 605

PostPosted: Mon Dec 08, 2008 5:54 am   
 
Kalie
If you want to be sure that your #T+/- kill1 command will not interfere with, say, a class (button, alias, etc.) with the same name in the future (if you accidentally create one), start using the #T's second parameter. #TPLUS

#T- kill1 trigger
Reply with quote
Fang Xianfu
GURU


Joined: 26 Jan 2004
Posts: 5155
Location: United Kingdom

PostPosted: Mon Dec 08, 2008 2:31 pm   
 
You can use #t+ and #t- regardless of the setting's location (it works for all settings, not just triggers). Just use it and it should work, as long as the IDs are unique.

You can use the second parameter if you have, say, a trigger with the same name as its class, though.

One thing, though - if the class is off, the trigger is off no matter what its "enabled" setting is. You can't have a trigger on inside a class that's off. So the trigger will only actually be checked if both are on - make sure they both are.
_________________
Rorso's syntax colouriser.

- Happy bunny is happy! (1/25)
Reply with quote
Kalie
Beginner


Joined: 23 Jun 2008
Posts: 22

PostPosted: Mon Dec 08, 2008 3:13 pm   
 
Got it! It's working now - I'm pretty sure I had a naming conflict that was getting me. Thanks guys. :)
Reply with quote
Display posts from previous:   
Post new topic   Reply to topic     Home » Forums » CMUD 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