Bugfix: only use pathfinder for monsters that are aggressive

This commit is contained in:
Oskar Wiksten
2013-08-08 11:31:06 +02:00
parent a83271c3a9
commit 16e8a5fdbe

View File

@@ -101,7 +101,7 @@ public final class MonsterMovementController implements EvaluateWalkable {
}
private void determineMonsterNextPosition(Monster m, MonsterSpawnArea area, Coord playerPosition) {
if (m.getMovementAggressionType() == MonsterType.AggressionType.protectSpawn) {
if (m.getMovementAggressionType() == MonsterType.AggressionType.protectSpawn && m.isAgressive()) {
if (area.area.contains(playerPosition)) {
if (findPathFor(m, playerPosition)) return;
}