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 Goto page Previous  1, 2
Sam Posted: Tue Aug 06, 2002 5:37 pm
Anti-trigger afflictions.
Sam
Beginner


Joined: 15 Jul 2002
Posts: 18

PostPosted: Fri Aug 09, 2002 9:11 pm   
 
Doesnt work properly with "%2". :(
Reply with quote
Kjata
GURU


Joined: 10 Oct 2000
Posts: 4379
Location: USA

PostPosted: Fri Aug 09, 2002 9:48 pm   
 
I get no such problem when testing with the sample output your provided. However, try making this change to the trigger and see if it still happens:
#TRIGGER {~*} {#VAR affline "A pr ickly stinging overwhelms your body.";#VAR affliction {%line};#WHILE (%pos("*", @affliction)) {#VAR affline {%delete(@affline, %pos("*", @affliction), 1)};#VAR affliction {%delete(@affliction, %pos("*", @affliction), 1)}};#IF ((@affliction = @affline) and (@affline <> "")) {cure affliction}}

Kjata
Reply with quote
LEit
Novice


Joined: 27 Jul 2002
Posts: 38
Location: USA

PostPosted: Mon Aug 12, 2002 5:01 pm   
 
If you're still having problems you could make an assumption that there will never be more then one * in the first 3 characters, and do this:

#TR {A p{r|*}{i|*}{c|*}{k|*}{l|*}{y|*}{ |*}{s|*}{t|*}{i|*}{n|*}{g|*}{i|*}{n|*}{g|*}{ |*}{o|*}} {CureAfflection}
#TR {A ~*{r|*}{i|*}{c|*}{k|*}{l|*}{y|*}{ |*}{s|*}{t|*}{i|*}{n|*}{g|*}{i|*}{n|*}{g|*}{ |*}{o|*}} {CureAfflection}
#TR {A~*p{r|*}{i|*}{c|*}{k|*}{l|*}{y|*}{ |*}{s|*}{t|*}{i|*}{n|*}{g|*}{i|*}{n|*}{g|*}{ |*}{o|*}} {CureAfflection}
#TR {~* p{r|*}{i|*}{c|*}{k|*}{l|*}{y|*}{ |*}{s|*}{t|*}{i|*}{n|*}{g|*}{i|*}{n|*}{g|*}{ |*}{o|*}} {CureAfflection}
#ALIAS CureAfflection {cure it here}

If there is more then one * in the first 3 characters you could add more lines, as long as you never get 3 for 3 you won't have to worry about matching the shop line
Reply with quote
Sam
Beginner


Joined: 15 Jul 2002
Posts: 18

PostPosted: Mon Aug 12, 2002 7:42 pm   
 
Thanks Kjata,

Sorry about the delay in response. I wanted to fully test it .. works perfectly now :) Appreciate all your effort helping me.

LEit,

Sounds like a good.. I will give it a try just to see :)
Reply with quote
Etheriel
Newbie


Joined: 24 Aug 2002
Posts: 3
Location: USA

PostPosted: Sat Aug 24, 2002 7:19 am   
 
in the shops, all the asterics are togeather. In the 'a prickl...' there is (to my knowledge) no asterics in the space(s) between the words in the line.

ie.. you wont see "A*prickly*".

I use something to the effect of this: (first few letters so I dont need the whole bloody thing)

{A|*}{ | }{p|*}{r|*}{i|*}{c|*}{k|*}
please note the spaces on either side of the | after the 'a'. this says it *has* to have a space after the first letter.

by adding that space, you only need one trigger, and none of this extra stuff.. Keep it simple. ;)

~Etheriel

#killall //dont put this in an alias.
Reply with quote
Etheriel
Newbie


Joined: 24 Aug 2002
Posts: 3
Location: USA

PostPosted: Sat Aug 24, 2002 7:23 am   
 
Apparantly the 'p' word is obscene! pri-ckly. sorry for any confusion.

quote:

ie.. you wont see "A*prickly*".



~Etheriel

#killall //dont put this in an alias.
Reply with quote
Display posts from previous:   
Post new topic   Reply to topic     Home » Forums » zMUD General Discussion All times are GMT
Goto page Previous  1, 2
Page 2 of 2

 
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