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
geosmith
Wanderer


Joined: 23 Apr 2005
Posts: 57

PostPosted: Fri Mar 10, 2006 6:36 pm   

#SUB and the word "illusion".
 
Okay, this one's a little unusual - basically I'm trying to set up a trigger such that when a particular line appears (for example, "You may drink another healing elixir.") under a certain set of circumstances, it's replaced with the line "Illusion: You may drink another healing elixir.". I've set the value of the trigger as follows:

#SUB {<i>Illusion: You may drink another healing elixir.</i>}

However, for some reason it doesn't see to like the word "Illusion" being used there and replaces it in the output with the word "You". This only seems to happen with the word illusion, which is particularly frustrating because that's the one word I want to use. I've tried putting "" around it, and I've tried preceeding it with ~, but nothing seems to help.

Any advice on how to fix this, or even just an explanation of what's causing it, would be wonderful.
Reply with quote
campnic
Newbie


Joined: 05 Mar 2006
Posts: 8

PostPosted: Fri Mar 10, 2006 7:45 pm   
 
I am no expert, but I would try:

#SUB {~<i~>Illusion: You may drink another healing elixir.~</i~>}

Unfortunately, I'm at work so I can't be sure that that works.

good luck
Reply with quote
MattLofton
GURU


Joined: 23 Dec 2000
Posts: 4834
Location: USA

PostPosted: Fri Mar 10, 2006 9:26 pm   
 
My guess is that it's the colon that's messing you up. When using curly braces with #SUBSTITUTE, zmud actively processes whatever is contained therein which means html/mxp brackets and special characters (ie, the colon, the default focus character) can mess up your output.

I don't believe this happens when you use double-quotes, but then again using them will cause zmud not to expand variables and the like.
_________________
EDIT: I didn't like my old signature
Reply with quote
geosmith
Wanderer


Joined: 23 Apr 2005
Posts: 57

PostPosted: Fri Mar 10, 2006 9:35 pm   
 
The thing I don't understand, though, is why this problem only occurred with the word illusion, and each and every time changed it to the word "you", regardless of the surrounding text. I mean I changed it to "illusio" and "illusions" and it worked perfectly fine. Wondered if the word illusion itself had some meaning in zMUD.
Reply with quote
campnic
Newbie


Joined: 05 Mar 2006
Posts: 8

PostPosted: Sat Mar 11, 2006 5:37 pm   
 
Is illusion the name of your character?
Reply with quote
geosmith
Wanderer


Joined: 23 Apr 2005
Posts: 57

PostPosted: Sat Mar 11, 2006 9:03 pm   
 
No, nor is it my password, the name of the MUD or in any other way significant. That's what makes the whole thing so entirely bizarre.
Reply with quote
aliensurfer
Beginner


Joined: 11 Apr 2005
Posts: 17

PostPosted: Wed Mar 22, 2006 4:06 pm   
 
Just a thought, search through your system for Illusion. It might be you've entered a slightly incorrect #SUB or #GAG command before hand, or, your using a system imported from elsewhere that has already done something with that particular word.

Hope that helps.
Reply with quote
Draman
Newbie


Joined: 26 Dec 2004
Posts: 2

PostPosted: Fri Mar 24, 2006 1:55 am   
 
I'm far from an expert with zmud Code, but I've always had problems with colons. I'm not on my computer, so I don't have zMUD with me, but you might try something like..

#SUB {<i>Illusion~: You may drink another healing elixir.</i>} if none of the others work.

I honestly have no clue if that will help at all, just trying to help.

PS. Looks like something from Aetolia/Achaea :P
Reply with quote
Llohr
Apprentice


Joined: 17 May 2005
Posts: 108

PostPosted: Fri Mar 24, 2006 2:26 am   
 
I'd have to agree with aliensurfer, you may have accidently created an alias or substition using that word, so it's messing you up in this trigger, I've had similar problems in the past.

Llohr
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