From b8e68533b99bdeeb994bd5c34bd678ec26bcca32 Mon Sep 17 00:00:00 2001 From: Evan Debenham Date: Sun, 6 Oct 2024 13:50:07 -0400 Subject: [PATCH] v2.5.4: fixed instakill effects not working on raging brutes (they are working on healthy brutes. i.e. they set health to 0 and trigger enraging) --- .../shatteredpixel/shatteredpixeldungeon/actors/Char.java | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/actors/Char.java b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/actors/Char.java index 0976b5e00..3044f7603 100644 --- a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/actors/Char.java +++ b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/actors/Char.java @@ -80,6 +80,7 @@ import com.shatteredpixel.shatteredpixeldungeon.actors.hero.Talent; import com.shatteredpixel.shatteredpixeldungeon.actors.hero.abilities.duelist.Challenge; import com.shatteredpixel.shatteredpixeldungeon.actors.hero.abilities.rogue.DeathMark; import com.shatteredpixel.shatteredpixeldungeon.actors.hero.abilities.warrior.Endure; +import com.shatteredpixel.shatteredpixeldungeon.actors.mobs.Brute; import com.shatteredpixel.shatteredpixeldungeon.actors.mobs.CrystalSpire; import com.shatteredpixel.shatteredpixeldungeon.actors.mobs.DwarfKing; import com.shatteredpixel.shatteredpixeldungeon.actors.mobs.Elemental; @@ -480,6 +481,9 @@ public abstract class Char extends Actor { if (enemy.isAlive() && enemy.alignment != alignment && prep != null && prep.canKO(enemy)){ enemy.HP = 0; + if (enemy.buff(Brute.BruteRage.class) != null){ + enemy.buff(Brute.BruteRage.class).detach(); + } if (!enemy.isAlive()) { enemy.die(this); } else { @@ -498,6 +502,9 @@ public abstract class Char extends Actor { && !Char.hasProp(enemy, Property.MINIBOSS) && (enemy.HP/(float)enemy.HT) <= 0.4f*((Hero)this).pointsInTalent(Talent.COMBINED_LETHALITY)/3f) { enemy.HP = 0; + if (enemy.buff(Brute.BruteRage.class) != null){ + enemy.buff(Brute.BruteRage.class).detach(); + } if (!enemy.isAlive()) { enemy.die(this); } else {