v2.3.0: fixed healing floating text spam on rot lashers

This commit is contained in:
Evan Debenham
2023-12-08 13:04:45 -05:00
parent 18311e138b
commit 77366a402e

View File

@@ -55,9 +55,9 @@ public class RotLasher extends Mob {
@Override
protected boolean act() {
if (enemy == null || !Dungeon.level.adjacent(pos, enemy.pos)) {
if (HP < HT && enemy == null || !Dungeon.level.adjacent(pos, enemy.pos)) {
sprite.showStatusWithIcon(CharSprite.POSITIVE, String.valueOf(Math.min(5, HT - HP)), FloatingText.HEALING);
HP = Math.min(HT, HP + 5);
sprite.showStatusWithIcon(CharSprite.POSITIVE, "5", FloatingText.HEALING);
}
return super.act();
}