From 7ddccd23a94752d18d97f0a44fca787118718abb Mon Sep 17 00:00:00 2001 From: Evan Debenham Date: Thu, 27 Aug 2020 11:37:08 -0400 Subject: [PATCH] v0.8.2c: swarm intelligence no longer overrides stunning effects --- .../shatteredpixeldungeon/actors/mobs/Mob.java | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/actors/mobs/Mob.java b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/actors/mobs/Mob.java index 99ed9e5e1..16d72c3f6 100644 --- a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/actors/mobs/Mob.java +++ b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/actors/mobs/Mob.java @@ -781,7 +781,9 @@ public abstract class Mob extends Char { if (alignment == Alignment.ENEMY && Dungeon.isChallenged( Challenges.SWARM_INTELLIGENCE )) { for (Mob mob : Dungeon.level.mobs) { - if (Dungeon.level.distance(pos, mob.pos) <= 8 && mob.state != mob.HUNTING) { + if (mob.paralysed <= 0 + && Dungeon.level.distance(pos, mob.pos) <= 8 //TODO base on pathfinder distance instead? + && mob.state != mob.HUNTING) { mob.beckon( target ); } } @@ -827,7 +829,9 @@ public abstract class Mob extends Char { if (alignment == Alignment.ENEMY && Dungeon.isChallenged( Challenges.SWARM_INTELLIGENCE )) { for (Mob mob : Dungeon.level.mobs) { - if (Dungeon.level.distance(pos, mob.pos) <= 8 && mob.state != mob.HUNTING) { + if (mob.paralysed <= 0 + && Dungeon.level.distance(pos, mob.pos) <= 8 //TODO base on pathfinder distance instead? + && mob.state != mob.HUNTING) { mob.beckon( target ); } }