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 );