mirror of
https://github.com/yairm210/Unciv.git
synced 2025-09-24 12:05:54 -04:00
Boni -> Bonuses, this is English
This commit is contained in:
parent
d69b458481
commit
6043a62353
@ -285,7 +285,7 @@ object SpecificUnitAutomation {
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* If there's a city nearby that can construct a wonder, walk there an get it built. Typically I
|
* If there's a city nearby that can construct a wonder, walk there an get it built. Typically I
|
||||||
* like to build all wonders in the same city to have the boni accumulate (and it typically ends
|
* like to build all wonders in the same city to have the bonuses accumulate (and it typically ends
|
||||||
* up being my capital), but that would need too much logic (e.g. how far away is the capital,
|
* up being my capital), but that would need too much logic (e.g. how far away is the capital,
|
||||||
* is the wonder likely still available by the time I'm there, is this particular wonder even
|
* is the wonder likely still available by the time I'm there, is this particular wonder even
|
||||||
* buildable in the capital, etc.)
|
* buildable in the capital, etc.)
|
||||||
|
@ -158,11 +158,11 @@ class Nation : RulesetObject() {
|
|||||||
fun addBonusLines(header: String, uniqueMap: UniqueMap) {
|
fun addBonusLines(header: String, uniqueMap: UniqueMap) {
|
||||||
// Note: Using getCityStateBonuses would be nice, but it's bound to a CityStateFunctions instance without even using `this`.
|
// Note: Using getCityStateBonuses would be nice, but it's bound to a CityStateFunctions instance without even using `this`.
|
||||||
// Too convoluted to reuse that here - but feel free to refactor that into a static.
|
// Too convoluted to reuse that here - but feel free to refactor that into a static.
|
||||||
val boni = uniqueMap.getAllUniques().filterNot { it.isHiddenToUsers() }
|
val bonuses = uniqueMap.getAllUniques().filterNot { it.isHiddenToUsers() }
|
||||||
if (boni.none()) return
|
if (bonuses.none()) return
|
||||||
textList += FormattedLine()
|
textList += FormattedLine()
|
||||||
textList += FormattedLine("{$header:} ")
|
textList += FormattedLine("{$header:} ")
|
||||||
for (unique in boni) {
|
for (unique in bonuses) {
|
||||||
textList += FormattedLine(unique, indent = 1)
|
textList += FormattedLine(unique, indent = 1)
|
||||||
if (unique.isOfType(UniqueType.CityStateUniqueLuxury)) showResources = true
|
if (unique.isOfType(UniqueType.CityStateUniqueLuxury)) showResources = true
|
||||||
}
|
}
|
||||||
|
@ -177,11 +177,11 @@ class CityStateDiplomacyTable(private val diplomacyScreen: DiplomacyScreen) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
fun getBonusText(header: String, level: RelationshipLevel): String {
|
fun getBonusText(header: String, level: RelationshipLevel): String {
|
||||||
val boni = viewingCiv.cityStateFunctions
|
val bonuses = viewingCiv.cityStateFunctions
|
||||||
.getCityStateBonuses(otherCiv.cityStateType, level)
|
.getCityStateBonuses(otherCiv.cityStateType, level)
|
||||||
.filterNot { it.isHiddenToUsers() }
|
.filterNot { it.isHiddenToUsers() }
|
||||||
if (boni.none()) return ""
|
if (bonuses.none()) return ""
|
||||||
return (sequenceOf(header) + boni.map { it.text }).joinToString(separator = "\n") { it.tr() }
|
return (sequenceOf(header) + bonuses.map { it.text }).joinToString(separator = "\n") { it.tr() }
|
||||||
}
|
}
|
||||||
fun addBonusLabel(header: String, bonusLevel: RelationshipLevel, relationLevel: RelationshipLevel) {
|
fun addBonusLabel(header: String, bonusLevel: RelationshipLevel, relationLevel: RelationshipLevel) {
|
||||||
val bonusLabelColor = if (relationLevel == bonusLevel) Color.GREEN else Color.GRAY
|
val bonusLabelColor = if (relationLevel == bonusLevel) Color.GREEN else Color.GRAY
|
||||||
|
Loading…
x
Reference in New Issue
Block a user