Andrettin / Wyrmsun

Strategy game based on history, mythology and fiction
http://andrettin.github.io/
GNU General Public License v2.0
301 stars 47 forks source link

Archers die very fast #129

Closed KroArtem closed 7 years ago

KroArtem commented 7 years ago

It seems like there is a fixed number of HP in percent from which hero will be auto-healed, like "heal when HP becomes less than 20%". As archers have less armour and less HP, they often die before they get auto-healed.

Andrettin commented 7 years ago

It wasn't done in percent, but in absolute numbers - a hero used a potion if the difference between their max and current HP values were greater than or equal to the quantity of HP the potions would heal. This meant that if a unit had less max HP than 45 (how much potions heal for), it would never use healing potions. I've made it so units will now use a potion both in the aforementioned case, and if their health is too low in terms of percentage (10% or lower), which should at least alleviate this issue: https://github.com/Andrettin/Wyrmgus/commit/003c61e8d613cc7ccc1e6e256284ef35a31c8b52

KroArtem commented 7 years ago

My current archer has 55 HP and (as far as I remember) zero armor, so when he is 5HP, he should heal. However, a lot of enemies can attack more than 5 hp at once, so when I'm 6 HP and still not healed, it's a dead end for my archer.

Andrettin commented 7 years ago

Hmm with 55 HP he should also heal when at 10 HP (since a Potion of Healing heals for 45 HP). In any case, I've increased the threshold to 20% instead of 10%.

KroArtem commented 7 years ago

Will check it this evening.

KroArtem commented 7 years ago

It's much better now, thanks. I think this ticket can be closed.

Andrettin commented 7 years ago

I'm glad to hear :)