v3.2.5: fixed guards pulling large chargs into enclosed spaces
This commit is contained in:
@@ -80,7 +80,9 @@ public class Guard extends Mob {
|
|||||||
else {
|
else {
|
||||||
int newPos = -1;
|
int newPos = -1;
|
||||||
for (int i : chain.subPath(1, chain.dist)){
|
for (int i : chain.subPath(1, chain.dist)){
|
||||||
if (!Dungeon.level.solid[i] && Actor.findChar(i) == null){
|
//find the closest position to the guard that's open for the target
|
||||||
|
if (!Dungeon.level.solid[i] && Actor.findChar(i) == null
|
||||||
|
&& (Dungeon.level.openSpace[i] || !Char.hasProp(enemy, Property.LARGE))){
|
||||||
newPos = i;
|
newPos = i;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user