mirror of
https://github.com/yairm210/Unciv.git
synced 2025-01-31 18:04:55 +07:00
More #12522 edge case
This commit is contained in:
parent
72329aec94
commit
7fbdfd13e5
@ -333,7 +333,8 @@ object UnitAutomation {
|
||||
}
|
||||
if (unit.movement.canUnitSwapTo(retreatTile)) {
|
||||
unit.movement.headTowards(retreatTile) // we need to move through the intermediate tiles
|
||||
if (unit.currentTile.neighbors.contains(otherUnit.currentTile)) {
|
||||
// if nothing changed
|
||||
if (unit.currentTile.neighbors.contains(otherUnit.currentTile) && unit.movement.canUnitSwapTo(retreatTile)) {
|
||||
unit.movement.swapMoveToTile(retreatTile)
|
||||
}
|
||||
return true
|
||||
|
Loading…
Reference in New Issue
Block a user