Page MenuHomeWildfire Games

Heal HP → Health, Rate → Interval
ClosedPublic

Authored by Nescio on Jun 28 2020, 12:24 PM.

Details

Summary

Currently the <Heal> node in the healer templates has two poorly named nodes: <HP> and <Rate>. This patch renames those to <Health> and <Interval>, respectively.
<HP> is undesirable, because everywhere else health is referred to as health.
<Rate> is confusing (cf. D2840), since it's actually not a rate, but a time.

Test Plan

Check for mistakes and omissions. Effectively everything should work exactly the same as before.

Diff Detail

Repository
rP 0 A.D. Public Repository
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.

Event Timeline

Nescio created this revision.Jun 28 2020, 12:24 PM
Owners added subscribers: Restricted Owners Package, Restricted Owners Package.Jun 28 2020, 12:24 PM
Nescio updated this revision to Diff 12483.Jun 28 2020, 12:29 PM

Build failure - The Moirai have given mortals hearts that can endure.

Link to build: https://jenkins.wildfiregames.com/job/docker-differential/2545/display/redirect

Build failure - The Moirai have given mortals hearts that can endure.

Link to build: https://jenkins.wildfiregames.com/job/docker-differential/2546/display/redirect

bb added a subscriber: bb.Jul 21 2020, 1:09 PM

Shouldn't we use Hitpoints instead of Health?
And if you wish consistancy with the attack component you would get repeatTime instead of interval

binaries/data/mods/public/simulation/data/technologies/heal_rate.json
8 ↗(On Diff #12483)

Should this change too?

binaries/data/mods/public/simulation/data/technologies/heal_rate_2.json
8 ↗(On Diff #12483)

same

Shouldn't we use Hitpoints instead of Health?

No, 0 A.D. use “Health” (almost) everywhere else. HP, health points, hit points, and vitality are terminology from other games. Also, I believe Health is the most generic: https://en.wikipedia.org/wiki/Health_(game_terminology) Furthermore, we don't use “Armour Points”, “Attack Points”, “Damage Points”, or “Resource Points” either.

And if you wish consistancy with the attack component you would get repeatTime instead of interval

I actually considered that initially, but decided against, because the <Heal> component does not have a <PrepareTime> either. <Interval> is used by e.g. <ResourceTrickle>. Interval is also more precise, I like proper language. However, if you think <RepeatTime> is intrinsically better, I suppose I could change it.

binaries/data/mods/public/gui/common/tooltips.js
189–198 ↗(On Diff #12483)

As you can see the attack tooltips actually use “interval”.

397–398 ↗(On Diff #12483)

Also here.

binaries/data/mods/public/simulation/data/technologies/heal_rate.json
8 ↗(On Diff #12483)

"description" is for historical background information, "tooltip" (below) for the actual modifications. The former is rather free flavour text, the latter should adhere to the style guide.

8 ↗(On Diff #12483)

This description does not say anything meaningful and thus ought to be replaced, yes, though not because of this patch.
You're welcome to suggest something. Otherwise the string could be kept for now and rewritten in a future patch.

binaries/data/mods/public/simulation/data/technologies/heal_rate_2.json
8 ↗(On Diff #12483)

Idem.

bb accepted this revision.Jul 21 2020, 3:41 PM
bb removed a reviewer: Restricted Owners Package.
bb added inline comments.
binaries/data/mods/public/simulation/components/Heal.js
17 ↗(On Diff #12483)

adding some free periods

This revision is now accepted and ready to land.Jul 21 2020, 3:41 PM
This revision was landed with ongoing or failed builds.Jul 21 2020, 6:29 PM
This revision was automatically updated to reflect the committed changes.

Thank you! This should make things less confusing for players and translaters alike.

And if you wish consistancy with the attack component you would get repeatTime instead of interval

I suppose one could consider replacing <RepeatTime> with <Interval> in the <Attack> node too. However, the current name is clear enough and works, so that would probably too much hassle for no real gain.