From 9ac85d3d773dd4970a495c48ed033db835be882a Mon Sep 17 00:00:00 2001 From: Evan Debenham Date: Sun, 29 Nov 2020 20:43:57 -0500 Subject: [PATCH] v0.9.1: fixed downed ghouls not dying when nearby ghouls are corrupted --- .../shatteredpixeldungeon/actors/mobs/Ghoul.java | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/actors/mobs/Ghoul.java b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/actors/mobs/Ghoul.java index 652f4d4ae..9b6ba6e84 100644 --- a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/actors/mobs/Ghoul.java +++ b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/actors/mobs/Ghoul.java @@ -223,6 +223,11 @@ public class Ghoul extends Mob { public boolean act() { ghoul.sprite.visible = Dungeon.level.heroFOV[ghoul.pos]; + if (target.alignment != ghoul.alignment){ + detach(); + return true; + } + if (target.fieldOfView == null){ target.fieldOfView = new boolean[Dungeon.level.length()]; Dungeon.level.updateFieldOfView( target, target.fieldOfView );