trigger-segfault / OpenLRR

An open source re-implementation of LEGO Rock Raiders 🪨⛏
66 stars 5 forks source link

Minus sign inconsistently shows in damage numbers #73

Closed trigger-segfault closed 1 year ago

trigger-segfault commented 1 year ago

Describe the issue When a unit receives damage, it shows the number of health points it lost above its head. By default, a - minus sign is shown in front of the number because the number represents health lost. However, this symbol doesn't always show. This is because the game doesn't hide or unhide the mesh group used to display the minus sign, so whether the sign shows depends on the last time the damage text was shown and the Nth character was not a minus sign.

Expected behaviour A minus sign should always show next to health lost from a unit (with the exception of zero, but that's a different story).

Steps to reproduce

  1. Start up Driller Night with debug keys enabled.
  2. Select a unit and press F to damage the unit for 40 points (a minus sign should show).
  3. Repeatedly tell a unit to move around the corner of the lava until it steps on the lava for a short enough time to lose health in the single digits (a minus sign should still show). Make sure to only do this with one unit, if two damage numbers are shown at once, then you can't guarantee the issue will be reproduced.
  4. Select a unit that has more than 40 health and press F to damage the unit for 40 points (a minus sign should not show any more).

Additional information