From 4dca1836353c343be242b14cdf33d4b499529207 Mon Sep 17 00:00:00 2001 From: Yair Morgenstern Date: Wed, 16 Nov 2022 22:53:08 +0200 Subject: [PATCH] Tile info table no longer reveals hidden units - see #7670 --- core/src/com/unciv/logic/map/TileInfo.kt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/core/src/com/unciv/logic/map/TileInfo.kt b/core/src/com/unciv/logic/map/TileInfo.kt index a3c9a9cd99..f7a4616a37 100644 --- a/core/src/com/unciv/logic/map/TileInfo.kt +++ b/core/src/com/unciv/logic/map/TileInfo.kt @@ -1000,7 +1000,7 @@ open class TileInfo : IsPartOfGameInfoSerialization { if (civilianUnit != null && isViewableToPlayer) lineList += FormattedLine(civilianUnit!!.name.tr() + " - " + civilianUnit!!.civInfo.civName.tr(), link="Unit/${civilianUnit!!.name}") - if (militaryUnit != null && isViewableToPlayer) { + if (militaryUnit != null && isViewableToPlayer && (viewingCiv == null || !militaryUnit!!.isInvisible(viewingCiv))) { val milUnitString = militaryUnit!!.name.tr() + (if (militaryUnit!!.health < 100) "(" + militaryUnit!!.health + ")" else "") + " - " + militaryUnit!!.civInfo.civName.tr()