 |
Lorrin Newbie
Joined: 18 Mar 2004 Posts: 1
|
Posted: Thu Mar 18, 2004 12:16 pm
Catching colour from a prompt |
Heyas all...im pretty new to zmud, having spent last 2 years using mm2k.
Im trying to import some scripts across (mainly to prove that it can be done). The main area im struggling with at the moment is capturing the colour of my hps. My current prompt is:
[STUFF]<999hp 999mana 999br 999mv>[STUFF]
But all the colours are metered (provided by the MUD i.e. Red when they are low, yellow when ok and blue when near full)....i want to capture these colours so i can relay my condition on chat (without having to include things like max hps in my prompt).
Thanks
-Lorrin |
|
|
 |
Kjata GURU

Joined: 10 Oct 2000 Posts: 4379 Location: USA
|
Posted: Thu Mar 18, 2004 12:29 pm |
Yes, you can capture the color. Just make sure the trigger is an Ansi Trigger (in the Options) and then you can use * to match the color codes. Example:
#TRIGGER {~<(*)%dhp *%dmana *%dbr *%dmv~>} {...} "" {color|prompt}
Now, %1 should have the correct color code. |
|
|
 |
|
|