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


Joined: 26 May 2012
Posts: 4

PostPosted: Sat May 26, 2012 1:21 am   

i need help im trying to show the direction a person flees in red
 
(*) panics, and attempts to flee.


and with in lines 1 i have the command #psub {%ansi(red,bold)%2} {%x2}
i dont know if i dont have a box checked or something like that pleeeese help !
Reply with quote
Rahab
Wizard


Joined: 22 Mar 2007
Posts: 2320

PostPosted: Sat May 26, 2012 3:59 pm   
 
You need to provide more information. Open this trigger in the Package Editor, then click the XML tab at the bottom of the editor box. Copy and paste the XML code into your response, putting it inside [code]...[/code] tags. Also, give us a sample text from the mud which includes both the panics line and the direction line.
Reply with quote
blackmojo713
Newbie


Joined: 26 May 2012
Posts: 4

PostPosted: Sun May 27, 2012 12:46 am   
 
A cat panics, and attempts to flee.
A cat leaves north.


<trigger type="Within Lines" param="1" priority="910" id="91">
<pattern>(*) panics, and attempts to flee.</pattern>
<trigger param="1">
<value>#psub {%ansi(red,bold)%2} {%x2}</value>
</trigger>
</trigger>
Reply with quote
Rahab
Wizard


Joined: 22 Mar 2007
Posts: 2320

PostPosted: Sun May 27, 2012 1:34 am   
 
There are several things wrong with that trigger.
1) The "panics" trigger state should be a normal trigger, i.e. "pattern" type, not a "within lines" trigger.
2) The second trigger state should be the "within lines" type.
3) The second trigger state has no pattern. It will match a null, which means it will match any line, but nothing is captured, so there is no %2 and nothing for the psub to work on.
Reply with quote
blackmojo713
Newbie


Joined: 26 May 2012
Posts: 4

PostPosted: Sun May 27, 2012 2:54 am   
 
im not great with triggers someone made it for me and maybe i set it up wrong
any chance you can walk me thew how to do it ?
Reply with quote
Rahab
Wizard


Joined: 22 Mar 2007
Posts: 2320

PostPosted: Tue May 29, 2012 1:20 pm   
 
I will assume that you only want the "north" part in red, rather than the entire "A cat leaves north". So:

Delete the existing trigger.
Cut and paste the following lines into the command line. You can paste the entire thing at once:
Code:

#TRIGGER {* panics, and attempts to flee.} {}
#COND {* leaves (*).} {#psub {%ansi(red,bold)%1%ansi(default)} %x1} {Within|Param=1}
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