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
quigbrew
Novice


Joined: 04 Jun 2002
Posts: 31

PostPosted: Fri Feb 04, 2005 1:16 am   

making a #cw trigger a priority over other #cw triggers
 
Anyone know if there's a way to make a trigger a priority over another similar trigger? I have two triggers that color individuals seperate colors. One trigger colors my current target red and the other trigger colors a group of people green. I want to make the red trigger a priority over all other color triggers, so if I have someone targetted they'll always be red.

Here's the triggers:

Current Target:
Pattern: @1
Value: #cw 12

Group color trigger:
Pattern: {Bob|Joey|Samantha|Kim}
Value: #cw 10

Right now the group trigger is taking the priority over my current target trigger. I've tried rearranging the placement of the triggers in the settings and that doesn't seem to do any good. Anyone have any ideas?
Thanks
Reply with quote
jessew
Apprentice


Joined: 03 Mar 2003
Posts: 141

PostPosted: Fri Feb 04, 2005 3:33 am   
 
One solution is to have your group trigger check if the match is also current target if it is not then color it.

lets say your currenttarget is in variable CURTARG

#TRIGGER {({Bob|Joey|Samantha|Kima})} {#if (%1 != @CURTARG) {#CW 10}}
_________________
I love deadlines. I like the whooshing sound they make as they fly by.
Reply with quote
LightBulb
MASTER


Joined: 28 Nov 2000
Posts: 4817
Location: USA

PostPosted: Fri Feb 04, 2005 3:05 pm   
 
The #CW trigger which comes last will set the color you see. To revise the order quickly, just delete the @1 trigger then remake it.
Code:
#UNTR {@1}
#TR {@1} {#CW 12}
_________________
LightBulb
Senior member

Most scripts in this forum are written for Command Line entry.
Don't even open the Settings Editor unless its use is specified or obvious.
Reply with quote
quigbrew
Novice


Joined: 04 Jun 2002
Posts: 31

PostPosted: Sat Feb 05, 2005 4:53 pm   
 
thanks lightbulb, that works great.....but (you knew there had to be a but).....it only works if all the other color triggers use the numerical value of a color (ie #cw 12 = bright red). For some reason the target trigger just won't out prioritize other trigger that color certain people using the common name listed in %colorname.

I.E.
the target trigger refuses to be dominate over a few other triggers I have that color certain people in the following colors:
wheat
darkorchid
goldenrod
cornflowerblue
etc
etc

no matter what I seem to do, I can't make the target variable trigger the dominate trigger. It works fine if a trigger uses the numerical value, but it refuses to squash triggers that use commonnames listed in %colorname. To add to the delima, it doesn't seem that those fancy common name colors have a numerical value assigned to them..at least not how zmud wants them.

Anyway, any help would greatly be appreciated.
Thanks
Reply with quote
LightBulb
MASTER


Joined: 28 Nov 2000
Posts: 4817
Location: USA

PostPosted: Mon Feb 07, 2005 1:46 am   
 
If the %colorname colors don't mix with the standard colors, then don't mix them. Decide which you want to use and do all your triggers one way or the other. It might require a lot of work now to convert triggers, but you'll only need to do it once.
Code:
#UNTR {@1}
#TR {@1} {#CW mxpred}
_________________
LightBulb
Senior member

Most scripts in this forum are written for Command Line entry.
Don't even open the Settings Editor unless its use is specified or obvious.
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