From 6be79671f363f5d557f430a01d993a7f97d77e38 Mon Sep 17 00:00:00 2001 From: Yair Morgenstern Date: Fri, 16 Jun 2023 11:17:26 +0300 Subject: [PATCH] Automated air units no longer lose "automated" state after moving between cities --- core/src/com/unciv/logic/map/mapunit/UnitMovement.kt | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/core/src/com/unciv/logic/map/mapunit/UnitMovement.kt b/core/src/com/unciv/logic/map/mapunit/UnitMovement.kt index e158400f0b..985c260797 100644 --- a/core/src/com/unciv/logic/map/mapunit/UnitMovement.kt +++ b/core/src/com/unciv/logic/map/mapunit/UnitMovement.kt @@ -7,6 +7,7 @@ import com.unciv.logic.map.BFS import com.unciv.logic.map.HexMath.getDistance import com.unciv.logic.map.tile.RoadStatus import com.unciv.logic.map.tile.Tile +import com.unciv.models.UnitActionType import com.unciv.models.helpers.UnitMovementMemoryType import com.unciv.models.ruleset.unique.StateForConditionals import com.unciv.models.ruleset.unique.UniqueType @@ -528,7 +529,7 @@ class UnitMovement(val unit: MapUnit) { if (unit.baseUnit.movesLikeAirUnits()) { // air units move differently from all other units - unit.action = null + if (unit.action != UnitActionType.Automate.value) unit.action = null unit.removeFromTile() unit.isTransported = false // it has left the carrier by own means unit.putInTile(destination)