mirror of
https://github.com/yairm210/Unciv.git
synced 2025-01-10 07:16:54 +07:00
Converted all era uniques to conditional uniques for city-states
This commit is contained in:
parent
4ab0b62a7f
commit
ee2ab74715
@ -1,32 +1,55 @@
|
||||
[
|
||||
{
|
||||
"name":"Cultured",
|
||||
"friendBonusUniques": ["[+3 Culture]"],
|
||||
"allyBonusUniques": ["[+6 Culture]"],
|
||||
"name": "Cultured",
|
||||
"friendBonusUniques": [
|
||||
"[+3 Culture] <before the [Medieval era]>",
|
||||
"[+6 Culture] <starting from the [Medieval era]> <before the [Industrial era]>",
|
||||
"[+13 Culture] <starting from the [Industrial era]>"
|
||||
],
|
||||
"allyBonusUniques": [
|
||||
"[+6 Culture] <before the [Medieval era]>",
|
||||
"[+12 Culture] <starting from the [Medieval era]> <before the [Industrial era]>",
|
||||
"[+26 Culture] <starting from the [Industrial era]>"
|
||||
],
|
||||
"color": [139, 96, 255]
|
||||
},
|
||||
{
|
||||
"name":"Maritime",
|
||||
"name": "Maritime",
|
||||
"friendBonusUniques": ["[+2 Food] [in capital]"],
|
||||
"allyBonusUniques": ["[+2 Food] [in capital]", "[+1 Food] [in all cities]"],
|
||||
"color": [56, 255, 112]
|
||||
},
|
||||
{
|
||||
"name":"Mercantile",
|
||||
"friendBonusUniques": ["[+2 Happiness]"],
|
||||
"allyBonusUniques": ["[+2 Happiness]", "Provides a unique luxury"],
|
||||
"name": "Mercantile",
|
||||
"friendBonusUniques": [
|
||||
"[+2 Happiness] <before the [Medieval era]>",
|
||||
"[+3 Happiness] <starting from the [Medieval era]>"
|
||||
],
|
||||
"allyBonusUniques": [
|
||||
"[+2 Happiness] <before the [Medieval era]>",
|
||||
"[+3 Happiness] <starting from the [Medieval era]>",
|
||||
"Provides a unique luxury"
|
||||
],
|
||||
"color": [255, 216, 0]
|
||||
},
|
||||
{
|
||||
"name":"Militaristic",
|
||||
"name": "Militaristic",
|
||||
"friendBonusUniques": ["Provides military units every ≈[20] turns"],
|
||||
"allyBonusUniques": ["Provides military units every ≈[17] turns"],
|
||||
"color": [255, 0, 0]
|
||||
},
|
||||
{
|
||||
"name":"Religious",
|
||||
"friendBonusUniques": ["[+3 Faith]"],
|
||||
"allyBonusUniques": ["[+6 Faith]"],
|
||||
"friendBonusUniques": [
|
||||
"[+3 Faith] <before the [Medieval era]>",
|
||||
"[+6 Faith] <starting from the [Medieval era]> <before the [Industrial era]>",
|
||||
"[+13 Faith] <starting from the [Industrial era]>"
|
||||
],
|
||||
"allyBonusUniques": [
|
||||
"[+6 Faith] <before the [Medieval era]>",
|
||||
"[+12 Faith] <starting from the [Medieval era]> <before the [Industrial era]>",
|
||||
"[+26 Faith] <starting from the [Industrial era]>"
|
||||
],
|
||||
"color": [255, 255, 255]
|
||||
}
|
||||
]
|
||||
|
@ -14,20 +14,6 @@
|
||||
"embarkDefense": 3,
|
||||
"startPercent": 0,
|
||||
"citySound": "cityAncient",
|
||||
"friendBonus": {
|
||||
"Cultured": ["Provides [+3 Culture] per turn"],
|
||||
"Maritime": ["Provides [+2 Food] [in capital] per turn"],
|
||||
"Mercantile": ["Provides [+2] Happiness"],
|
||||
"Religious": ["Provides [+3 Faith] per turn"],
|
||||
"Militaristic": ["Provides military units every ≈[20] turns"]
|
||||
},
|
||||
"allyBonus": {
|
||||
"Cultured": ["Provides [+6 Culture] per turn"],
|
||||
"Maritime": ["Provides [+2 Food] [in capital] per turn", "Provides [+1 Food] [in all cities] per turn"],
|
||||
"Mercantile": ["Provides [+2] Happiness", "Provides a unique luxury"],
|
||||
"Religious": ["Provides [+6 Faith] per turn"],
|
||||
"Militaristic": ["Provides military units every ≈[17] turns"]
|
||||
},
|
||||
"iconRGB": [255, 87, 35]
|
||||
},
|
||||
{
|
||||
@ -44,20 +30,6 @@
|
||||
"embarkDefense": 4,
|
||||
"startPercent": 10,
|
||||
"citySound": "cityClassical",
|
||||
"friendBonus": {
|
||||
"Cultured": ["Provides [+3 Culture] per turn"],
|
||||
"Maritime": ["Provides [+2 Food] [in capital] per turn"],
|
||||
"Mercantile": ["Provides [+2] Happiness"],
|
||||
"Religious": ["Provides [+3 Faith] per turn"],
|
||||
"Militaristic": ["Provides military units every ≈[20] turns"]
|
||||
},
|
||||
"allyBonus": {
|
||||
"Cultured": ["Provides [+6 Culture] per turn"],
|
||||
"Maritime": ["Provides [+2 Food] [in capital] per turn", "Provides [+1 Food] [in all cities] per turn"],
|
||||
"Mercantile": ["Provides [+2] Happiness", "Provides a unique luxury"],
|
||||
"Religious": ["Provides [+6 Faith] per turn"],
|
||||
"Militaristic": ["Provides military units every ≈[17] turns"]
|
||||
},
|
||||
"iconRGB": [233, 31, 99]
|
||||
},
|
||||
{
|
||||
@ -79,20 +51,6 @@
|
||||
"embarkDefense": 6,
|
||||
"startPercent": 25,
|
||||
"citySound": "cityMedieval",
|
||||
"friendBonus": {
|
||||
"Cultured": ["Provides [+6 Culture] per turn"],
|
||||
"Maritime": ["Provides [+2 Food] [in capital] per turn"],
|
||||
"Mercantile": ["Provides [+3] Happiness"],
|
||||
"Religious": ["Provides [+6 Faith] per turn"],
|
||||
"Militaristic": ["Provides military units every ≈[20] turns"]
|
||||
},
|
||||
"allyBonus": {
|
||||
"Cultured": ["Provides [+12 Culture] per turn"],
|
||||
"Maritime": ["Provides [+2 Food] [in capital] per turn", "Provides [+1 Food] [in all cities] per turn"],
|
||||
"Mercantile": ["Provides [+3] Happiness", "Provides a unique luxury"],
|
||||
"Religious": ["Provides [+12 Faith] per turn"],
|
||||
"Militaristic": ["Provides military units every ≈[17] turns"]
|
||||
},
|
||||
"iconRGB": [157, 39, 176]
|
||||
},
|
||||
{
|
||||
@ -112,20 +70,6 @@
|
||||
"embarkDefense": 8,
|
||||
"startPercent": 37,
|
||||
"citySound": "cityRenaissance",
|
||||
"friendBonus": {
|
||||
"Cultured": ["Provides [+6 Culture] per turn"],
|
||||
"Maritime": ["Provides [+2 Food] [in capital] per turn"],
|
||||
"Mercantile": ["Provides [+3] Happiness"],
|
||||
"Religious": ["Provides [+6 Faith] per turn"],
|
||||
"Militaristic": ["Provides military units every ≈[20] turns"]
|
||||
},
|
||||
"allyBonus": {
|
||||
"Cultured": ["Provides [+12 Culture] per turn"],
|
||||
"Maritime": ["Provides [+2 Food] [in capital] per turn", "Provides [+1 Food] [in all cities] per turn"],
|
||||
"Mercantile": ["Provides [+3] Happiness", "Provides a unique luxury"],
|
||||
"Religious": ["Provides [+12 Faith] per turn"],
|
||||
"Militaristic": ["Provides military units every ≈[17] turns"]
|
||||
},
|
||||
"uniques": ["Every major Civilization gains a spy once a civilization enters this era"],
|
||||
"iconRGB": [104, 58, 183]
|
||||
},
|
||||
@ -147,20 +91,6 @@
|
||||
"embarkDefense": 10,
|
||||
"startPercent": 50,
|
||||
"citySound": "cityIndustrial",
|
||||
"friendBonus": {
|
||||
"Cultured": ["Provides [+13 Culture] per turn"],
|
||||
"Maritime": ["Provides [+2 Food] [in capital] per turn"],
|
||||
"Mercantile": ["Provides [+3] Happiness"],
|
||||
"Religious": ["Provides [+13 Faith] per turn"],
|
||||
"Militaristic": ["Provides military units every ≈[20] turns"]
|
||||
},
|
||||
"allyBonus": {
|
||||
"Cultured": ["Provides [+26 Culture] per turn"],
|
||||
"Maritime": ["Provides [+2 Food] [in capital] per turn", "Provides [+1 Food] [in all cities] per turn"],
|
||||
"Mercantile": ["Provides [+3] Happiness", "Provides a unique luxury"],
|
||||
"Religious": ["Provides [+26 Faith] per turn"],
|
||||
"Militaristic": ["Provides military units every ≈[17] turns"]
|
||||
},
|
||||
"iconRGB": [63, 81, 182],
|
||||
"uniques": ["May not generate great prophet equivalents naturally",
|
||||
"May buy [Great Prophet] units for [200] [Faith] [in all cities in which the majority religion is a major religion] at an increasing price ([100])",
|
||||
@ -187,20 +117,6 @@
|
||||
"embarkDefense": 13,
|
||||
"startPercent": 65,
|
||||
"citySound": "cityModern",
|
||||
"friendBonus": {
|
||||
"Cultured": ["Provides [+13 Culture] per turn"],
|
||||
"Maritime": ["Provides [+2 Food] [in capital] per turn"],
|
||||
"Mercantile": ["Provides [+3] Happiness"],
|
||||
"Religious": ["Provides [+13 Faith] per turn"],
|
||||
"Militaristic": ["Provides military units every ≈[20] turns"]
|
||||
},
|
||||
"allyBonus": {
|
||||
"Cultured": ["Provides [+26 Culture] per turn"],
|
||||
"Maritime": ["Provides [+2 Food] [in capital] per turn", "Provides [+1 Food] [in all cities] per turn"],
|
||||
"Mercantile": ["Provides [+3] Happiness", "Provides a unique luxury"],
|
||||
"Religious": ["Provides [+26 Faith] per turn"],
|
||||
"Militaristic": ["Provides military units every ≈[17] turns"]
|
||||
},
|
||||
"iconRGB": [33, 150, 243],
|
||||
"uniques": ["May not generate great prophet equivalents naturally",
|
||||
"May buy [Great Prophet] units for [200] [Faith] [in all cities in which the majority religion is a major religion] at an increasing price ([100])",
|
||||
@ -228,20 +144,6 @@
|
||||
"embarkDefense": 16,
|
||||
"startPercent": 65,
|
||||
"citySound": "cityAtomic",
|
||||
"friendBonus": {
|
||||
"Cultured": ["Provides [+13 Culture] per turn"],
|
||||
"Maritime": ["Provides [+2 Food] [in capital] per turn"],
|
||||
"Mercantile": ["Provides [+3] Happiness"],
|
||||
"Religious": ["Provides [+13 Faith] per turn"],
|
||||
"Militaristic": ["Provides military units every ≈[20] turns"]
|
||||
},
|
||||
"allyBonus": {
|
||||
"Cultured": ["Provides [+26 Culture] per turn"],
|
||||
"Maritime": ["Provides [+2 Food] [in capital] per turn", "Provides [+1 Food] [in all cities] per turn"],
|
||||
"Mercantile": ["Provides [+3] Happiness", "Provides a unique luxury"],
|
||||
"Religious": ["Provides [+26 Faith] per turn"],
|
||||
"Militaristic": ["Provides military units every ≈[17] turns"]
|
||||
},
|
||||
"iconRGB": [0, 150, 136],
|
||||
"uniques": ["May not generate great prophet equivalents naturally",
|
||||
"May buy [Great Prophet] units for [200] [Faith] [in all cities in which the majority religion is a major religion] at an increasing price ([100])",
|
||||
@ -271,21 +173,6 @@
|
||||
"startPercent": 80,
|
||||
|
||||
"citySound": "cityInformation",
|
||||
"friendBonus": {
|
||||
"Cultured": ["Provides [+13 Culture] per turn"],
|
||||
"Maritime": ["Provides [+2 Food] [in capital] per turn"],
|
||||
"Mercantile": ["Provides [+3] Happiness"],
|
||||
"Religious": ["Provides [+13 Faith] per turn"],
|
||||
"Militaristic": ["Provides military units every ≈[20] turns"]
|
||||
},
|
||||
"allyBonus": {
|
||||
"Cultured": ["Provides [+26 Culture] per turn"],
|
||||
"Maritime": ["Provides [+2 Food] [in capital] per turn", "Provides [+1 Food] [in all cities] per turn"],
|
||||
"Mercantile": ["Provides [+3] Happiness", "Provides a unique luxury"],
|
||||
"Religious": ["Provides [+26 Faith] per turn"],
|
||||
"Militaristic": ["Provides military units every ≈[17] turns"]
|
||||
|
||||
},
|
||||
"iconRGB": [76, 176, 81],
|
||||
"uniques": ["May not generate great prophet equivalents naturally",
|
||||
"May buy [Great Prophet] units for [200] [Faith] [in all cities in which the majority religion is a major religion] at an increasing price ([100])",
|
||||
@ -316,21 +203,6 @@
|
||||
"embarkDefense": 25,
|
||||
"startPercent": 80,
|
||||
"citySound": "cityFuture",
|
||||
"friendBonus": {
|
||||
"Cultured": ["Provides [+13 Culture] per turn"],
|
||||
"Maritime": ["Provides [+2 Food] [in capital] per turn"],
|
||||
"Mercantile": ["Provides [+3] Happiness"],
|
||||
"Religious": ["Provides [+13 Faith] per turn"],
|
||||
"Militaristic": ["Provides military units every ≈[20] turns"]
|
||||
},
|
||||
"allyBonus": {
|
||||
"Cultured": ["Provides [+26 Culture] per turn"],
|
||||
"Maritime": ["Provides [+2 Food] [in capital] per turn", "Provides [+1 Food] [in all cities] per turn"],
|
||||
"Mercantile": ["Provides [+3] Happiness", "Provides a unique luxury"],
|
||||
"Religious": ["Provides [+26 Faith] per turn"],
|
||||
"Militaristic": ["Provides military units every ≈[17] turns"]
|
||||
|
||||
},
|
||||
"iconRGB": [76, 176, 81],
|
||||
"uniques": ["May not generate great prophet equivalents naturally",
|
||||
"May buy [Great Prophet] units for [200] [Faith] [in all cities in which the majority religion is a major religion] at an increasing price ([100])",
|
||||
|
@ -211,7 +211,7 @@ class Translations : LinkedHashMap<String, TranslationEntry>(){
|
||||
// Whenever this string is changed, it should also be changed in the translation files!
|
||||
// It is mostly used as the template for translating the order of conditionals
|
||||
const val englishConditionalOrderingString =
|
||||
"<with a garrison> <for [mapUnitFilter] units> <above [amount] HP> <below [amount] HP> <vs cities> <vs [mapUnitFilter] units> <when fighting in [tileFilter] tiles> <when attacking> <when defending> <if this city has at least [amount] specialists> <when at war> <when not at war> <while the empire is happy> <during a Golden Age> <during the [era]> <before the [era]> <starting from the [era]> <with [techOrPolicy]> <without [techOrPolicy]>"
|
||||
"<with a garrison> <for [mapUnitFilter] units> <above [amount] HP> <below [amount] HP> <vs cities> <vs [mapUnitFilter] units> <when fighting in [tileFilter] tiles> <when attacking> <when defending> <if this city has at least [amount] specialists> <when at war> <when not at war> <while the empire is happy> <during a Golden Age> <during the [era]> <starting from the [era]> <before the [era]> <with [techOrPolicy]> <without [techOrPolicy]>"
|
||||
const val conditionalUniqueOrderString = "ConditionalsPlacement"
|
||||
const val shouldCapitalizeString = "StartWithCapitalLetter"
|
||||
}
|
||||
@ -305,7 +305,7 @@ fun String.tr(): String {
|
||||
var translatedBaseUnique = this.removeConditionals().tr()
|
||||
|
||||
val conditionals = this.getConditionals().map { it.placeholderText }
|
||||
val conditionsWithTranslation: HashMap<String, String> = hashMapOf()
|
||||
val conditionsWithTranslation: LinkedHashMap<String, String> = linkedMapOf()
|
||||
|
||||
for (conditional in this.getConditionals())
|
||||
conditionsWithTranslation[conditional.placeholderText] = conditional.text.tr()
|
||||
|
@ -248,15 +248,15 @@ class DiplomacyScreen(
|
||||
|
||||
val eraInfo = viewingCiv.getEra()
|
||||
|
||||
var friendBonusText = "{When Friends:} ".tr()
|
||||
var friendBonusText = "{When Friends:}\n".tr()
|
||||
val friendBonusObjects = eraInfo.getCityStateBonuses(otherCiv.cityStateType, RelationshipLevel.Friend)
|
||||
val friendBonusStrings = getAdjustedBonuses(friendBonusObjects)
|
||||
friendBonusText += friendBonusStrings.joinToString(separator = ", ") { it.tr() }
|
||||
friendBonusText += friendBonusStrings.joinToString(separator = "\n") { it.tr() }
|
||||
|
||||
var allyBonusText = "{When Allies:} ".tr()
|
||||
var allyBonusText = "{When Allies:}\n".tr()
|
||||
val allyBonusObjects = eraInfo.getCityStateBonuses(otherCiv.cityStateType, RelationshipLevel.Ally)
|
||||
val allyBonusStrings = getAdjustedBonuses(allyBonusObjects)
|
||||
allyBonusText += allyBonusStrings.joinToString(separator = ", ") { it.tr() }
|
||||
allyBonusText += allyBonusStrings.joinToString(separator = "\n") { it.tr() }
|
||||
|
||||
val relationLevel = otherCivDiplomacyManager.relationshipLevel()
|
||||
if (relationLevel >= RelationshipLevel.Friend) {
|
||||
|
Loading…
Reference in New Issue
Block a user