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
Vorax
Apprentice


Joined: 29 Jun 2001
Posts: 198
Location: USA

PostPosted: Wed Aug 07, 2002 1:05 pm   

using #CW to color a line w/ special characters
 
I have a few triggers to color different communication channels differently. The problem is, when there is one of the special characters in the line, the line doesn't get colored.

#Trig {%w gossips, '*'.}{#CW red}
Someone gossips, 'Blah!'.
with the above trigger, that line would be colored red, but
Someone gossips, 'Blah ###!'.
that line would not.

When testing the pattern, it says it doesn't match, so, what I'm asking is, how do I get the pattern to match so that lines with the special characters DO get colored and the special character remain in the colored line?
Reply with quote
Kjata
GURU


Joined: 10 Oct 2000
Posts: 4379
Location: USA

PostPosted: Wed Aug 07, 2002 2:24 pm   
 
Change the * wildcard to %* which will match special zMUD characters. Using this wildcard in the way you are using it (ie. whatever is matched by it is not used in the script) is safe. However, if you were to use the text matched by it in a script, great care should be taken to prevent players from executing unwanted commands in your zMUD.

Kjata
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