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


Joined: 04 Feb 2014
Posts: 42

PostPosted: Thu Feb 18, 2016 6:41 am   

Using a Multi Word - String List variable Trigger
 
I have a variable that contains a few things:

Code:
#CLASS {SubsnColors}
#VAR rankgear {a jeweled wristcuff |a pair of steel-plated greaves |a heron marked blade }
#TRIGGER {{@rankgear}} {#CW darkmagenta}
#CLASS 0


I can't get the rankgear to expand to be any one of the stringlist. Can I can get some help with this?

I just want it to try for anytime i see, someone wearing, or on the ground one of those 3 items, to color the text darkmagenta.

Thanks![/code]


Last edited by MisterDwooD on Sat Feb 20, 2016 6:21 pm; edited 1 time in total
Reply with quote
shalimar
GURU


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

PostPosted: Thu Feb 18, 2016 2:45 pm   
 
Looks like you padded every value with a space for some reason.
Removing the trailing space should fix things.
_________________
Windows 10 Home Premium 64-bit
AMD Phenom II x6 1055T 2.8GHz 16GB
CMUD Pro v3.34
Reply with quote
Vijilante
SubAdmin


Joined: 18 Nov 2001
Posts: 5182

PostPosted: Thu Feb 18, 2016 3:43 pm   
 
zMud won't expand the list in the pattern automatically. That feature exists in CMud. To do it in zMud you must enter the list directly into the pattern.
_________________
The only good questions are the ones we have never answered before.
Search the Forums
Reply with quote
MisterDwooD
Novice


Joined: 04 Feb 2014
Posts: 42

PostPosted: Thu Feb 18, 2016 7:54 pm   
 
Yeah. I test it pretty fully. It seems like it'll trigger on a single word, or multiple single words. But, if the string list contains values that are multiple words, then it doesn't expand it.

So what you're saying is that I need to have the trigger like:

#TRIGGER {{a jeweled wristcuff|a pair of steel-plated greaves|a heron marked blade}} {#CW darkmagenta}

I was just hoping to avoid using the list like that, and just use a variable and then add to the list of the variable.

So that's the only way? No way to trigger off @whatever and have it be full lists of gear?

Thanks!
Reply with quote
shalimar
GURU


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

PostPosted: Thu Feb 18, 2016 8:15 pm   
 
I thought it used to work... bad memory I suppose.
You could upgrade to CMUD, cheaper than a new console game.
_________________
Windows 10 Home Premium 64-bit
AMD Phenom II x6 1055T 2.8GHz 16GB
CMUD Pro v3.34
Reply with quote
MisterDwooD
Novice


Joined: 04 Feb 2014
Posts: 42

PostPosted: Fri Feb 19, 2016 4:34 am   
 
Actually, I already bought CMUD. I'm a supporter for sure! I love the Z/C Mud :)

But.. In Cmud, i can't "semi-colon space" and have it go through. That was a mistake in zmud, Mr. Zugg already told me that. So, I'd have to redo my habits, who wants to do that!

And... I've tried converting everything... It was a no go. Now, if you want to try and convert my mud file to CMUD. :) I might take you up on it! But, No way i'm fixing the thousands of lines that need help.

Anyways.

Thanks for your help! Always great hearing from yall grand masters!
Reply with quote
shalimar
GURU


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

PostPosted: Fri Feb 19, 2016 6:49 am   
 
Think of it like this....
Imagine how much more efficient your settings would be knowing what you know now.
Either way, feel free to continue asking question, we can likely help you through all of your growing pains.
_________________
Windows 10 Home Premium 64-bit
AMD Phenom II x6 1055T 2.8GHz 16GB
CMUD Pro v3.34
Reply with quote
Medakan
Novice


Joined: 15 Dec 2015
Posts: 36
Location: Seattle

PostPosted: Fri Feb 19, 2016 10:24 pm   
 
MisterDwooD,
That equipment looks like gear from WoTmud...

Might have an idea for a work around, will check something tonight after work
Reply with quote
Edogg
Beginner


Joined: 27 Feb 2011
Posts: 17

PostPosted: Sat Feb 20, 2016 4:52 pm   
 
change your trigger to a regular expression

#CLASS {SubsnColors}
#VAR rankgear {a jeweled wristcuff|a pair of steel-plated greaves|a heron marked blade}
#REGEX {@rankgear} {#CW darkmagenta}
#CLASS 0
Reply with quote
shalimar
GURU


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

PostPosted: Sat Feb 20, 2016 5:59 pm   
 
What is the purpose of sending a semicolon space?
_________________
Windows 10 Home Premium 64-bit
AMD Phenom II x6 1055T 2.8GHz 16GB
CMUD Pro v3.34
Reply with quote
MisterDwooD
Novice


Joined: 04 Feb 2014
Posts: 42

PostPosted: Tue Mar 08, 2016 4:15 pm   
 
When i'm entering commands in the command bar is when it mattered to me. Not while writing scripts. For example:

st; not; mw; charge bob

that is not the same as:

st;not;mw;chargebob

One of those does not work, either it requires spaces, or it does not like spaces in cMUD. I addressed Zugg about the issue and he said that it actually an issue in zMUD that let it work both ways.

That's what I meant by what I said.
Reply with quote
shalimar
GURU


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

PostPosted: Wed Mar 09, 2016 3:56 am   
 
It works as intended for command separation when no spaces are used.
I believe the other formats were kludged to not be command separation, not sure why, likely because so many games used the semicolon for other purposes and people were resistant to just escaping out the semicolon with a tilde: ~;
_________________
Windows 10 Home Premium 64-bit
AMD Phenom II x6 1055T 2.8GHz 16GB
CMUD Pro v3.34
Reply with quote
Einder
Novice


Joined: 03 Jan 2008
Posts: 48

PostPosted: Tue Jul 26, 2016 7:06 am   
 
try
Code:
 ({@rankgear})


I use a lot of different string lists through variables in my zMud coding, simply because it's easier to add or delete without changing an entire trigger.

Sorry I wasn't able to give you a response sooner, I know this is months later, but sometimes it's better late than never right?
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