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


Joined: 16 Aug 2005
Posts: 8

PostPosted: Tue Dec 20, 2005 1:18 am   

weird error with !=
 
Hi, I decided to try something out, and was wondering what the syntax was:

Here's the trigger
A clay cup of simple design fills to overflowing with %1.

#IF %1!="water" {empty cup} {}


Here's what happened:
A clay cup of simple design fills to overflowing with orange juice.

zmud sent this back to the mud:
juice!=water

I'm kind of lost as to what happened. This is in zMUD 7.20b
Reply with quote
Vitae
Enchanter


Joined: 17 Jun 2005
Posts: 673
Location: New York

PostPosted: Tue Dec 20, 2005 2:17 am   
 
#trigger {A clay cup of simple design fills to overflowing with (*).} {#if (%1 != "water" {empty cup} {}}
_________________
http://www.Aardwolf.com
Reply with quote
Pseudo
Wanderer


Joined: 25 Oct 2005
Posts: 99

PostPosted: Tue Dec 20, 2005 2:23 am   
 
#TRIGGER {A clay cup of simple design fills to overflowing with (%w).} {#IF (%1 != "water") {empty cup} {}}

%w will compare just the word or * will grab the rest of the line depending on your needs.
Vitae, your example is missing the closing ) in the #IF.
Reply with quote
Vitae
Enchanter


Joined: 17 Jun 2005
Posts: 673
Location: New York

PostPosted: Thu Dec 22, 2005 5:40 pm   
 
Pseudo, yeap, missed that closing ) :(
As for the %w, since his only example used 2 words orange juice I opted for the *
Tho thinking about it, is it %* or *...*shrug* he can try both and see which works :-)
_________________
http://www.Aardwolf.com
Reply with quote
MattLofton
GURU


Joined: 23 Dec 2000
Posts: 4834
Location: USA

PostPosted: Thu Dec 22, 2005 8:28 pm   
 
It's *. %* picks up anything that's printed to the screen, while * stops at the first special character.
_________________
EDIT: I didn't like my old signature
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