More Healthbar Help Needed

Posted by Mrs. Teacup on Mon 25 Oct 2004 11:59 PM — 12 posts, 37,214 views.

#0
First I would like to apologise outright on my lack of knowledge covering this subject but any help I can get would be much appreciated.

I'm using the Health_Bar plugin and have managed to get it loaded and I can see the grey line that comes up, however, the trigger part is leaving me at a complete loss at what to do.

I'm trying to make it work along these lines,
Hp: 1456(1456) Gp: 393(393) Xp: 127693
But I'm not sure what exactly I need to do with this and what needs added or changed.
USA #1
Change the line at the top of the plugin that has this:
"^\<\-?(\d+)\/(\d+) hp \-?(\d+)\/(\d+) m \-?(\d+)\/(\d+) mv\>(.*?)$"
to this:
"^Hp\: (\d+)\(\d+)\) Gp\: (\d+)\((\d+)\) Xp\: (\d+)(.*?)$"
However, you have information that the plugin isnt looking for.

The plugin works (by default) with hp, m (mana), and movement (which is six things).
You are giving it Hp, Gp, and Xp (which is five things).
so, youre going to have to change some of the plugin anyway to accomidate that. Shouldnt be too much though. I havent looked at it.
But that trigger will match.
#2
How do I program the health bar so that instead of responding to prompt <%h/%H hp %m/%M m %v/%V mv> it responds to CONFIG PROMPT ALL? The former command is obsolete in Achaea, and I don't know much about programming...thanks.
-Tresien
USA #3
Whats the prompt look like?
We'll need to know what each piece is, as well as the format.
#4
oh, sorry. The prompt is 1743h, 2046m, 7615e, 8200w ex-
e stands for equilibrium and x is balance
USA #5
h is health, m is mana, e is? w is?
Do you get totals, erm, max values?

And what exactly do the ex- at the end do?
They obviously wouldnt be put into bar form, but could still be included. You can tweak that to your own liking.

But most importantly, do you get maximum values for the numerics?

And I think this prompt has been done elsewhere, it looks dreadfully familiar. Try poking around, we might have already answered this question.
#6
argh, sorry. E is endurance and W is will. The ex- wouldn't be in the bar, I dunno why I put it there. I was having mental issues yesterday. In any case, it tells you whether you have equilibrium and balance. If the e is missing, you don't have equilibrium, if the x is missing, you don't have balance. Anyways, the values there are the max values for that particular character. I looked around the forums and couldn't find anything else, but I may not have looked hard enough. Thanks.
-Tres
USA #7
Youll use this prompt:
"^(\d+)h, (\d+)m, (\d+)e, (\d+)w e?x?-(.*)$"

Thats assuming that the prompt truncates if the e or x goes away (you get e- instead of e - if youre missing an x).

Replace that in the same way as mentioned above.

You'll also have to change the plugin to use built-in values for the maxes.
Will the max values ever change? If they do, we'll go about this differently, well, two ways we could.
But we'll assume that theyre static for now.

Line 138 or so, youll see this:
DoGauge " HP: ", wildcards (1), wildcards (2), "darkgreen", "maroon"
DoGauge " Mana: ", wildcards (3), wildcards (4), "mediumblue", "mediumblue"
DoGauge " Move: ", wildcards (5), wildcards (6), "gold", "gold"

You need to change that to:
DoGauge " HP: ", wildcards (1), 1743, "darkgreen", "maroon"
DoGauge " Mana: ", wildcards (2), 2046, "mediumblue", "mediumblue"
DoGauge " Endurance: ", wildcards (3), 7615, "gold", "gold"
DoGauge " Will: ", wildcards (4), 8200, "gold", "gold"

Obviously, you should change the colors on those to reflect something meaningful.
The first color is what it displays when its more than 20%, the second is 20% or less (you can change that percentage a couple dozen lines above those DoGauges).
#8
could you show me what it would look like if the max values change? Would I just enter "wildcards" where the numbers are? Sorry to bug you so much.
USA #9
How often do they change? Once every couple of weeks? Once per character? Or, quite often?

Also, is there anything you can check to get your max stats?
#10
Yeah, you can by typing in SCORE. The results look like this:

398h, 386m ex- [note: prompt]
score [note: echo of me typing SCORE]
Wakune (male Xoran)
You are level 2 (Bold) and 0% of the way to the next level.
Health: 398/398 Mana: 386/386
Endurance: 890/890 Willpower: 830/830
Strength: 14 Dexterity: 10 Constitution: 15 Intelligence: 13


with information that is not useful to the health bar following
#11
Hi...

I hope I'm not out of line bumping this old topic.

I was trying to get the health bar plugin to work for me, but being very very rusty with programming and never having used XML, I figured I'd ask experts for help.

My prompt looks like this:

%h (Hp%) %m (Mn%) %T TNL %o/%O (Mon%)->

Where %h is my current HP, Hp% is my hp as a percentage (or %h / %H, the mud computes this automatically), %m is my current mana, %T is my current TNL, %o is my monitored target's current HP, %O is my monitored target's max HP and Mon% is my monitor's hp as a percentage.

An example of this prompt would be:

1025 (22%) 2204 (100%) 201 TNL 2024/2024 (100%)->

When I'm not monitoring, the monitor shows up as "-/- (-)". Additionally, when I'm under sanctuary, sneaking, invis or moving hidden, the following appear before the prompt (respectively):

$#!@1025 (22%) 2204 (100%) 201 TNL -/- (-)->

What I'd like is to put the HP, mana and TNL on the status bar. I don't really want the monitor there and since I don't track mvs on my prompt, I figure I can just make the Moves bar be my TNL bar (using 2000 as max TNL).

Any help I can get on this would be greatly appreciated!

Thanks
-Dan