v0.9.3a: actually fixed giant swarms duplicating into enclosed spaces

This commit is contained in:
Evan Debenham 2021-06-11 20:56:55 -04:00
parent 0fb5c4a11f
commit e80bc2c1c0

View File

@ -89,7 +89,7 @@ public class Swarm extends Mob {
int[] neighbours = {pos + 1, pos - 1, pos + Dungeon.level.width(), pos - Dungeon.level.width()};
for (int n : neighbours) {
if (!Dungeon.level.solid[n] && Actor.findChar( n ) == null
&& (!properties.contains(Property.LARGE) || Dungeon.level.openSpace[n])) {
&& (!properties().contains(Property.LARGE) || Dungeon.level.openSpace[n])) {
candidates.add( n );
}
}