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


Joined: 12 Sep 2004
Posts: 5

PostPosted: Sun Sep 12, 2004 9:54 am   

Triggering prompt
 
I'm having difficulty triggering the prompt on a MUD I play. Usually it'd be simple, but I keep running into the same problem when trying to specify a range.

Here's a few examples of the prompt:

H:3000 M:3000 B:100% [eb]
H:3000 M:3000 B:100% [-b]
H:3000 M:3000 B:100% [e-]
H:3000 M:3000 B:100% [--]

Now, that would be easy for me to do, though sometimes the prompt can appear as:

H:3000 M:3000 B:100% [csdb eb]

which presents more problems, as I'm trying to differentiate the first "b" from the second, and the "-" characters in the prompt don't seem to let me create the range I'm looking for.

Using %pos, it seems difficult for me to have the first b (if there is one) letting me know that I have that defense, and having the second b letting me know something completely different.

I tried triggering it as:

^H:(%d) M:(%d) B:%d~% ~[(*)([-e-b])~]

but as I'm sure you can see, using "-" in a range has a different use than what I'm looking for.

If anyone can help, it'd be immensly appreciated.
Reply with quote
LightBulb
MASTER


Joined: 28 Nov 2000
Posts: 4817
Location: USA

PostPosted: Sun Sep 12, 2004 12:19 pm   
 
The one thing missing from your explanation is the method you use to differentiate between one b and the other. However, it appears that the last character will always be b or -, depending on balance, and the next-to-last character will always be e or -, depending on equilibrium. This means you only need to separate out those two.
^H:(%d) M:(%d) B:%d~% ~[(*)(&2)~]

You should bring this to the attention of whoever is responsible for the prompt. With 26 letters available, it should not have been necessary to use the same letter twice so this problem should never have occured.
_________________
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
Acidic
Newbie


Joined: 12 Sep 2004
Posts: 5

PostPosted: Sun Sep 12, 2004 2:24 pm   
 
Thank you, LightBulb, that works perfectly.
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