From cfcfb69e72b80b23f76b5f90a6c1a11ad6b26266 Mon Sep 17 00:00:00 2001 From: metablaster <44481081+metablaster@users.noreply.github.com> Date: Tue, 15 Jul 2025 10:51:29 +0200 Subject: [PATCH] Update incorrect demand message and refactor translation for 'an unknown civilization' (#13606) * fix broken translation * apply suggested change * fix untraslated string in load game screen * update incorrect demand message * refactor translation for an unknown civilization * fix spaces --- android/assets/jsons/translations/template.properties | 9 +-------- core/src/com/unciv/logic/battle/Nuke.kt | 2 +- core/src/com/unciv/logic/city/CityConstructions.kt | 4 ++-- .../unciv/logic/city/managers/CityConquestFunctions.kt | 4 ++-- .../src/com/unciv/logic/civilization/diplomacy/Demand.kt | 2 +- .../unciv/logic/civilization/managers/PolicyManager.kt | 2 +- .../models/ruleset/unique/UniqueTriggerActivation.kt | 2 +- .../unciv/ui/screens/diplomacyscreen/DiplomacyScreen.kt | 2 +- 8 files changed, 10 insertions(+), 17 deletions(-) diff --git a/android/assets/jsons/translations/template.properties b/android/assets/jsons/translations/template.properties index c14b07c6bb..fcf33b394d 100644 --- a/android/assets/jsons/translations/template.properties +++ b/android/assets/jsons/translations/template.properties @@ -143,7 +143,6 @@ Research Agreement = Declare war = Declare war on [civName]? = [civName] will also join them in the war = -An unknown civilization will also join them in the war = This will cancel your defensive pact with [civName] = Go to on map = Let's begin! = @@ -983,10 +982,8 @@ Cannot provide unit upkeep for [unitName] - unit has been disbanded! = [construction] has been built in [cityName] = [wonder] has been built in a faraway land = [civName] has completed [construction]! = -An unknown civilization has completed [construction]! = The city of [cityname] has started constructing [construction]! = [civilization] has started constructing [construction]! = -An unknown civilization has started constructing [construction]! = [cityName] has started working on [construction] = [cityName] has expanded its borders! = Your Golden Age has ended. = @@ -1044,7 +1041,6 @@ Your city [cityName] can bombard the enemy! = [amount] enemy units were spotted in our territory = A(n) [nukeType] from [civName] has exploded in our territory! = A(n) [nukeType] has been detonated by [civName]! = -A(n) [nukeType] has been detonated by an unknown civilization! = After an attempted attack by our [nukeType], [civName] has declared war on us! = After being hit by our [nukeType], [civName] has declared war on us! = The civilization of [civName] has been destroyed! = @@ -1112,7 +1108,6 @@ We Love The King Day in [cityName] has ended. = Our [name] took [tileDamage] tile damage and was destroyed = Our [name] took [tileDamage] tile damage = [civName] has adopted the [policyName] policy = -An unknown civilization has adopted the [policyName] policy = You gained [Stats] as your religion was spread to [cityName] = You gained [Stats] as your religion was spread to an unknown city = Your city [cityName] was converted to [religionName]! = @@ -1123,8 +1118,6 @@ You have unlocked [ability]! = A new b'ak'tun has just begun! = A Great Person joins you! = [civ1] has liberated [civ2] = -[civ] has liberated an unknown civilization = -An unknown civilization has liberated [civ] = # Trigger notifications @@ -1842,7 +1835,7 @@ Spy Hideout = Spy present = Move = -After an unknown civilization entered the [eraName], we have recruited [spyName] as a spy! = +After [unknownCiv] entered the [eraName], we have recruited [spyName] as a spy! = We have recruited [spyName] as a spy! = We have recruited a new spy name [spyName] after [oldSpyName] was killed. = Your spy [spyName] has leveled up! = diff --git a/core/src/com/unciv/logic/battle/Nuke.kt b/core/src/com/unciv/logic/battle/Nuke.kt index f23555cbff..113a820dda 100644 --- a/core/src/com/unciv/logic/battle/Nuke.kt +++ b/core/src/com/unciv/logic/battle/Nuke.kt @@ -141,7 +141,7 @@ object Nuke { ) else otherCiv.addNotification( - "A(n) [${attacker.getName()}] has been detonated by an unknown civilization!", + "A(n) [${attacker.getName()}] has been detonated by an [unknown civilization]!", nukeNotificationAction, NotificationCategory.War, NotificationIcon.War, attacker.getName() ) } diff --git a/core/src/com/unciv/logic/city/CityConstructions.kt b/core/src/com/unciv/logic/city/CityConstructions.kt index 22d0b3697b..046d95bf75 100644 --- a/core/src/com/unciv/logic/city/CityConstructions.kt +++ b/core/src/com/unciv/logic/city/CityConstructions.kt @@ -459,7 +459,7 @@ class CityConstructions : IsPartOfGameInfoSerialization { otherCiv.knows(city.civ) -> otherCiv.addNotification("[${city.civ.civName}] has started constructing [${construction.name}]!", NotificationCategory.General, NotificationIcon.Construction, icon) - else -> otherCiv.addNotification("An unknown civilization has started constructing [${construction.name}]!", + else -> otherCiv.addNotification("[An unknown civilization] has started constructing [${construction.name}]!", NotificationCategory.General, NotificationIcon.Construction, icon) } } @@ -545,7 +545,7 @@ class CityConstructions : IsPartOfGameInfoSerialization { // No need to notify ourself, since we already got the building notification anyway if (otherCiv == city.civ) continue val completingCivDescription = - if (otherCiv.knows(city.civ)) "[${city.civ.civName}]" else "An unknown civilization" + if (otherCiv.knows(city.civ)) "[${city.civ.civName}]" else "[An unknown civilization]" otherCiv.addNotification("$completingCivDescription has completed [${construction.name}]!", pediaAction, NotificationCategory.General, NotificationIcon.Construction, buildingIcon) } diff --git a/core/src/com/unciv/logic/city/managers/CityConquestFunctions.kt b/core/src/com/unciv/logic/city/managers/CityConquestFunctions.kt index 6444f0c815..228dafb20d 100644 --- a/core/src/com/unciv/logic/city/managers/CityConquestFunctions.kt +++ b/core/src/com/unciv/logic/city/managers/CityConquestFunctions.kt @@ -208,9 +208,9 @@ class CityConquestFunctions(val city: City) { civ.knows(conqueringCiv) && civ.knows(foundingCiv) -> civ.addNotification("[$conqueringCiv] has liberated [$foundingCiv]", NotificationCategory.Diplomacy, foundingCiv.civName, NotificationIcon.Diplomacy, conqueringCiv.civName) civ.knows(conqueringCiv) && !civ.knows(foundingCiv) -> - civ.addNotification("[$conqueringCiv] has liberated an unknown civilization", NotificationCategory.Diplomacy, NotificationIcon.Diplomacy, conqueringCiv.civName) + civ.addNotification("[$conqueringCiv] has liberated [an unknown civilization]", NotificationCategory.Diplomacy, NotificationIcon.Diplomacy, conqueringCiv.civName) !civ.knows(conqueringCiv) && civ.knows(foundingCiv) -> - civ.addNotification("An unknown civilization has liberated [$foundingCiv]", NotificationCategory.Diplomacy, NotificationIcon.Diplomacy, foundingCiv.civName) + civ.addNotification("[An unknown civilization] has liberated [$foundingCiv]", NotificationCategory.Diplomacy, NotificationIcon.Diplomacy, foundingCiv.civName) else -> continue } } diff --git a/core/src/com/unciv/logic/civilization/diplomacy/Demand.kt b/core/src/com/unciv/logic/civilization/diplomacy/Demand.kt index 7c63aa644a..c28cde7f57 100644 --- a/core/src/com/unciv/logic/civilization/diplomacy/Demand.kt +++ b/core/src/com/unciv/logic/civilization/diplomacy/Demand.kt @@ -61,7 +61,7 @@ enum class Demand( refuseDemandText = "We shall do as we please.", agreedToDemandText = "[civName] agreed to stop spreading religion to us!", refusedDemandText = "[civName] refused to stop spreading religion to us!", - violationNoticedText = "We noticed you have continued spreading your faith, despite your promise. This will have....consequences.", + violationNoticedText = "We noticed you have continued spreading your religion to us, despite your promise. This will have....consequences.", wePromisedText = "We promised not to spread religion to them ([turns] turns remaining)", theyPromisedText = "They promised not to spread religion to us ([turns] turns remaining)", ), diff --git a/core/src/com/unciv/logic/civilization/managers/PolicyManager.kt b/core/src/com/unciv/logic/civilization/managers/PolicyManager.kt index b33675b593..c71c2b6fd9 100644 --- a/core/src/com/unciv/logic/civilization/managers/PolicyManager.kt +++ b/core/src/com/unciv/logic/civilization/managers/PolicyManager.kt @@ -306,7 +306,7 @@ class PolicyManager : IsPartOfGameInfoSerialization { val defaultNotificationText = if (civ.getKnownCivs().contains(civInfo)) { "[${civInfo.civName}] has adopted the [${policy.name}] policy" } else { - "An unknown civilization has adopted the [${policy.name}] policy" + "[An unknown civilization] has adopted the [${policy.name}] policy" } civ.addNotification( "{${defaultNotificationText}} {${extraNotificationText}}", diff --git a/core/src/com/unciv/models/ruleset/unique/UniqueTriggerActivation.kt b/core/src/com/unciv/models/ruleset/unique/UniqueTriggerActivation.kt index 3390ad15c6..4440e10cd1 100644 --- a/core/src/com/unciv/models/ruleset/unique/UniqueTriggerActivation.kt +++ b/core/src/com/unciv/models/ruleset/unique/UniqueTriggerActivation.kt @@ -884,7 +884,7 @@ object UniqueTriggerActivation { // We don't tell which civilization entered the new era, as that is done in the notification directly above this one spy.addNotification("We have recruited [${spy.name}] as a spy!") else - spy.addNotification("After an unknown civilization entered the [$currentEra], we have recruited [${spy.name}] as a spy!") + spy.addNotification("After [an unknown civilization] entered the [$currentEra], we have recruited [${spy.name}] as a spy!") } } true diff --git a/core/src/com/unciv/ui/screens/diplomacyscreen/DiplomacyScreen.kt b/core/src/com/unciv/ui/screens/diplomacyscreen/DiplomacyScreen.kt index c73cb3f70b..50bdae84a5 100644 --- a/core/src/com/unciv/ui/screens/diplomacyscreen/DiplomacyScreen.kt +++ b/core/src/com/unciv/ui/screens/diplomacyscreen/DiplomacyScreen.kt @@ -339,7 +339,7 @@ class DiplomacyScreen( messageLines += if (viewingCiv.knows(civ)) { "[${civ.civName}] will also join them in the war" } else { - "An unknown civilization will also join them in the war" + "[An unknown civilization] will also join them in the war" } }