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
shalimar
GURU


Joined: 04 Aug 2002
Posts: 4794
Location: Pensacola, FL, USA

PostPosted: Mon Nov 10, 2003 4:38 am   

trigger issue
 
#TRIGGER {({@sir})} {#SUB {%concat("Sir ",%1)}}

it works but sometimes i get: Sir Sir Whoever
how can i do it and make sure it doesnt go off on itself again?
Reply with quote
LightBulb
MASTER


Joined: 28 Nov 2000
Posts: 4817
Location: USA

PostPosted: Mon Nov 10, 2003 7:29 pm   
 
#DELITEM sir {Sir Whoever}
#ADDITEM sir {Whoever}

Or, to do it quickly
#FORALL @sir {#IF (%word( {%i}, 1) = Sir) {#DELI sir {%i};#ADDI sir {%right( {%i}, 4)}}}

You could also simplify the trigger but that won't affect the problem.
#TR {({@sir})} {#SUB {Sir %1}}

None of this will help if someone tells you that Sir Whoever is in the tournament (or any other statement that already has "Sir" before a name in your list).
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