mirror of
https://git.krews.org/morningstar/Arcturus-Community.git
synced 2025-01-18 15:36:27 +01:00
Fix Room Blocking. Thanks #TheJava for helping.
This commit is contained in:
parent
344bed8b3d
commit
4be2f0a8ba
@ -300,7 +300,6 @@ public class RoomLayout {
|
||||
double height = currentAdj.getStackHeight() - current.getStackHeight();
|
||||
if (!ALLOW_FALLING && height < -MAXIMUM_STEP_HEIGHT) continue;
|
||||
if (currentAdj.state == RoomTileState.OPEN && height > MAXIMUM_STEP_HEIGHT) continue;
|
||||
|
||||
if (currentAdj.hasUnits() && ((!isWalktroughRetry && !this.room.isAllowWalkthrough()) || currentAdj.equals(goalLocation))) {
|
||||
closedList.add(currentAdj);
|
||||
openList.remove(currentAdj);
|
||||
@ -320,7 +319,7 @@ public class RoomLayout {
|
||||
}
|
||||
|
||||
if (!this.room.isAllowWalkthrough() && !isWalktroughRetry) {
|
||||
return this.findPath(oldTile, newTile, goalLocation, roomUnit, true);
|
||||
return this.findPath(oldTile, newTile, goalLocation, roomUnit, false);
|
||||
}
|
||||
|
||||
return null;
|
||||
|
Loading…
Reference in New Issue
Block a user