v1.4.3: fixed boss health bar not appearing or bleeding in some cases

This commit is contained in:
Evan Debenham
2022-10-31 13:44:25 -04:00
parent 340ac38bbb
commit aed061f248
2 changed files with 8 additions and 1 deletions

View File

@@ -139,6 +139,9 @@ public class DwarfKing extends Mob {
lastAbility = bundle.getInt( LAST_ABILITY );
if (phase == 2) properties.add(Property.IMMOVABLE);
BossHealthBar.assignBoss(this);
if (phase == 3) BossHealthBar.bleed(true);
}
@Override

View File

@@ -191,6 +191,7 @@ public class YogDzewa extends Mob {
yell(Messages.get(this, "hope"));
summonCooldown = -15; //summon a burst of minions!
phase = 5;
BossHealthBar.bleed(true);
}
if (phase == 0){
@@ -593,7 +594,10 @@ public class YogDzewa extends Mob {
public void restoreFromBundle(Bundle bundle) {
super.restoreFromBundle(bundle);
phase = bundle.getInt(PHASE);
if (phase != 0) BossHealthBar.assignBoss(this);
if (phase != 0) {
BossHealthBar.assignBoss(this);
if (phase == 5) BossHealthBar.bleed(true);
}
abilityCooldown = bundle.getFloat(ABILITY_CD);
summonCooldown = bundle.getFloat(SUMMON_CD);