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
Kage_
Newbie


Joined: 22 Mar 2009
Posts: 3

PostPosted: Sun Mar 22, 2009 12:37 am   

Coloring specific lines of text
 
Hello,

I'm new to CMUD and I'm trying to figure out what it can do. So far I have been able to color specific lines using keywords I specifiy. The problem I'm having is there is a line that matches a keyword, but I don't want it to color the line.

Here's my current setup:

Code:
Pattern: %w
#COLOR {says ^~(OOC~)} orange
#COLOR {exclaims} orange
#COLOR {asks} orange


I want it to color the line orange when the work says shows up, but I don't want it to mess with the line when the line contains says (OOC). Ultimately, I want the lines of 5 or so words/phrases flagged when they are said.

Any pointers?

Thanks,

Kage_
Reply with quote
Tech
GURU


Joined: 18 Oct 2000
Posts: 2733
Location: Atlanta, USA

PostPosted: Sun Mar 22, 2009 12:57 am   
 
You, my friend, are looking for the '^' not pattern Matching character. Something like this should help.

Code:
TRIGGER {says {^(OOC)}} {#COLOR orange}


Something like that should do the trick and color the lines that don't have "OOC" in them.
_________________
Asati di tempari!
Reply with quote
Kage_
Newbie


Joined: 22 Mar 2009
Posts: 3

PostPosted: Sun Mar 22, 2009 1:04 am   
 
Now if I wanted to stack several in one trigger, would the above work and add {^(OOC)} to the says entry?
Reply with quote
shalimar
GURU


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

PostPosted: Sun Mar 22, 2009 1:36 am   
 
if you have several, then i suggest an unnamed variable embedded in the pattern

#TR {says {^{(OOC)|option2|etc}}} {#CO orange}
_________________
Discord: Shalimarwildcat
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