Civilopedia: Improvement: show bonus for improvingTech (#2261)

* Civilopedia improvement techupgrade

* Fixed overzealous cleanup

* 3 Languages for the new line
This commit is contained in:
proteus-anguinus 2020-03-25 21:24:41 +01:00 committed by GitHub
parent 4219776329
commit 144d53b6df
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
5 changed files with 10 additions and 1 deletions

View file

@ -785,6 +785,7 @@ Available for [unitTypes] = Disponible pour [unitTypes]
Free promotion: = Promotion gratuite:
Free promotions: = Promocions gratuites:
Free for [units] = Libre pour [units]
[bonus] with [tech] = [bonus] avec [tech]
# Policies

View file

@ -784,6 +784,7 @@ Available for [unitTypes] = Verfügbar für [unitTypes]
Free promotion: = Freie Beförderung:
Free promotions: = Freie Beförderungen:
Free for [units] = Frei für [units]
[bonus] with [tech] = [bonus] mit [tech]
# Policies

View file

@ -875,6 +875,7 @@ Available for [unitTypes] = Disponible para [unitTypes]
Free promotion: = Ascenso libre:
Free promotions: = Ascensos libres:
Free for [units] = Libre para [units]
[bonus] with [tech] = [bonus] con [tech]
# Policies

View file

@ -783,6 +783,7 @@ Available for [unitTypes] =
Free promotion: =
Free promotions: =
Free for [units] =
[bonus] with [tech] =
# Policies

View file

@ -32,7 +32,12 @@ class TileImprovement : NamedStats() {
fun getDescription(ruleset: Ruleset, forPickerScreen: Boolean = true): String {
val stringBuilder = StringBuilder()
if (this.clone().toString().isNotEmpty()) stringBuilder.appendln(this.clone().toString())
val statsDesc = this.clone().toString()
if (statsDesc.isNotEmpty()) stringBuilder.appendln(statsDesc)
if (improvingTech != null && improvingTechStats != null) {
val improveStatsDesc = improvingTechStats.toString()
if (improveStatsDesc.isNotEmpty()) stringBuilder.appendln("[$improveStatsDesc] with [${improvingTech!!}]".tr())
}
if (uniqueTo!=null && !forPickerScreen) stringBuilder.appendln("Unique to [$uniqueTo]".tr())
if (!terrainsCanBeBuiltOn.isEmpty()) {
val terrainsCanBeBuiltOnString: ArrayList<String> = arrayListOf()