 |
Dunat Newbie
Joined: 22 Feb 2003 Posts: 2
|
Posted: Sat Feb 22, 2003 6:44 pm
zmud 3.62 healthchecker |
can anyone help me with this?been trying to work it out for ages,cant seem to make one that works,:)i suck at this kinda thing, would appreciate it if anyone could help,:)
|
|
|
|
 |
Emit Magician
Joined: 24 Feb 2001 Posts: 342 Location: USA
|
Posted: Sat Feb 22, 2003 11:54 pm |
#if (@hp > 500) {#show I'm ok.} {#show i'm hurt}
is about the best i can do with that amount of information .
What you'll probably want to do is create a trigger that fires on your prompt, stores your hitpoints to a variable, and then you can use commands like the one above. More information about exactly what you want the health checker to do, and sample output lines from your mud would be helpful.
--------
moon.icebound.net:9000 |
|
|
|
 |
Dunat Newbie
Joined: 22 Feb 2003 Posts: 2
|
Posted: Sun Feb 23, 2003 4:04 am |
okies sorry for that lack of info
basically when i type group it will come out as this:
Group information for Donuktanam and Company
Size: 2
Unsplit Coins: 0 platinum 0 gold 0 silver 0 copper
(Head) 896/896 hit, 109/109 move, 0/0 psp Donuktanam
102/102 hit, 189/189 move, 0/0 psp a huge cave lizard
i was trying to find a way to make it show in different colours if lets say someone is at 75% health,50% health or 25 % health,
cant seem to make any triggers that work on 3.62,:) |
|
|
|
 |
Emit Magician
Joined: 24 Feb 2001 Posts: 342 Location: USA
|
Posted: Sun Feb 23, 2003 6:32 am |
hmm, i thought of several solutions right off the bat for 6.53 . i tried to download 3.62 but couldn't get it to work. looking at the version history, i think your best bet is to use #gag and %ansi and #show:
#trigger {(*)(%d)/(%d) hit, (*)} {
#GAG
#VARIABLE hp %1
#VARIABLE maxhp %2
#VARIABLE pxp %eval( 100*@hp)
#IF (@pxp/@maxhp > 75) {
#SHOW %1 %ansi( green)%2%ansi( clear)/%3 %4} {
#IF (@pxp/@maxhp > 50) {
#SHOW %1 %ansi( blue)%2%ansi( clear)/%3 %4} {
#IF (@pxp/@maxhp > 25) {
#SHOW %1 %ansi( yellow)%2%ansi( clear)/%3 %4} {
#SHOW %1 %ansi( red)%2%ansi( clear)/%3 %4}}}
}
--------
moon.icebound.net:9000 |
|
|
|
 |
|
|
|