From b5c9fb79bf582b15367b0a4d9c87383a0d54e7b6 Mon Sep 17 00:00:00 2001 From: jnecus Date: Tue, 3 Nov 2020 18:10:54 +0000 Subject: [PATCH] FIx bug Carrier-based aircraft not healing (#3316) With reference to issue #3307 I think that aircraft on aircraft carriers were being treated at land units at sea. I have added the check to test whether they are being transported so that they should now heal whilst on aircraft carriers. --- core/src/com/unciv/logic/map/MapUnit.kt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/core/src/com/unciv/logic/map/MapUnit.kt b/core/src/com/unciv/logic/map/MapUnit.kt index 09e3ce833b..c679fe9ac8 100644 --- a/core/src/com/unciv/logic/map/MapUnit.kt +++ b/core/src/com/unciv/logic/map/MapUnit.kt @@ -406,7 +406,7 @@ class MapUnit { var healing = when { tileInfo.isCityCenter() -> 20 - tileInfo.isWater && isFriendlyTerritory && type.isWaterUnit() -> 15 // Water unit on friendly water + tileInfo.isWater && isFriendlyTerritory && (type.isWaterUnit() || isTransported) -> 15 // Water unit on friendly water tileInfo.isWater -> 0 // All other water cases tileInfo.getOwner() == null -> 10 // Neutral territory isFriendlyTerritory -> 15 // Allied territory