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


Joined: 08 Oct 2008
Posts: 1

PostPosted: Wed Oct 08, 2008 4:09 am   

help with configuring an echo?
 
The mud I play one can cast spells yet it looks like this when casting a spell:

Code:
[HP:  86%] [ME:  13%] [PE: 100%] [Wealth: zero]

You utter the words, 'qcandusahz yaae'.
A large golden apple suddenly appears.

[HP:  86%] [ME:   8%] [PE: 100%] [Wealth: zero]


The game I play the words I utter mean a certain spell and I'm trying to figure out how to get it to say the name of the spell without it being considered a command like it's doing here(notice the Huh? Type 'help' for a list of commands.):

Code:
[HP:  86%] [ME:  13%] [PE: 100%] [Wealth: zero]

You utter the words, 'qcandusahz yaae'.
create food
A large golden apple suddenly appears.

[HP:  86%] [ME:   8%] [PE: 100%] [Wealth: zero]
Huh?  Type 'help' for a list of commands.

[HP:  86%] [ME:   8%] [PE: 100%] [Wealth: zero]


This is how I'm wanting it to look like:

Code:
[HP:  86%] [ME:  13%] [PE: 100%] [Wealth: zero]

You utter the words, 'qcandusahz yaae'.
create food
A large golden apple suddenly appears.

[HP:  86%] [ME:   8%] [PE: 100%] [Wealth: zero]
Reply with quote
Dyron
Apprentice


Joined: 08 Apr 2004
Posts: 103
Location: USA

PostPosted: Wed Oct 08, 2008 6:32 am   
 
just do a simple #say or #echo it looks like...
Reply with quote
charneus
Wizard


Joined: 19 Jun 2005
Posts: 1876
Location: California

PostPosted: Wed Oct 08, 2008 6:51 am   
 
#SAY would probably work best.

#TRIGGER {Spell message here} {#SAY Spell here}

Or you could take it a step further and do:

#VAR spelldb {qcandusah yaae=create food|lerpeoskf deedka=create spring|etc...}

#TRIGGER {You utter the words, '({@spelldb})'} {#SUB {You utter the words, '%db(@spelldb, %1)'}}

Then, instead of the normal phrase, it'll say:

You utter the words, 'create food'

Anyway, just a couple solutions...

Charneus

Edited to correct the trigger pattern. Also corrected the trigger pattern, as it was wrong...


Last edited by charneus on Wed Oct 08, 2008 2:18 pm; edited 3 times in total
Reply with quote
Fang Xianfu
GURU


Joined: 26 Jan 2004
Posts: 5155
Location: United Kingdom

PostPosted: Wed Oct 08, 2008 8:16 am   
 
I personally would go for

#trigger {(You utter the words '({@spelldb})')} {#sub {%concat(%1," ",%db(@spelldb,%2)}

Which will give you the result:

You chant the words 'aakjgja gakgjaskg' Create Food

or whatever.

Also, charneus' pattern above won't work - it needs {} inside the (), like mine.
_________________
Rorso's syntax colouriser.

- Happy bunny is happy! (1/25)

Last edited by Fang Xianfu on Wed Oct 08, 2008 5:05 pm; edited 1 time in total
Reply with quote
ralgith
Sorcerer


Joined: 13 Jan 2006
Posts: 715

PostPosted: Wed Oct 08, 2008 1:41 pm   
 
You could also do it as a #SUB and then you'd be replacing the magical language with the plain words on your screen only. Instead of just tacking them onto the end like Fang did ;)
_________________
CrossOver: Windows Compatibility on Mac and Linux CMUD Advocate
Reply with quote
charneus
Wizard


Joined: 19 Jun 2005
Posts: 1876
Location: California

PostPosted: Wed Oct 08, 2008 2:05 pm   
 
Thanks Fang. I was posting from my phone and it was late at night, ugh. Didn't have a real chance to look over it before posting it.

Ralgith, that's exactly what mine does. :p

Charneus
Reply with quote
ralgith
Sorcerer


Joined: 13 Jan 2006
Posts: 715

PostPosted: Wed Oct 08, 2008 6:03 pm   
 
Sorry Charn, I missed that somehow LOL!!! I think I skipped your post completely.
_________________
CrossOver: Windows Compatibility on Mac and Linux CMUD Advocate
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