tileResource unique fully replaceable by uniques

This commit is contained in:
yairm210 2021-09-19 20:58:17 +03:00
parent dbac2bfccb
commit aee087ec01
3 changed files with 8 additions and 8 deletions

View File

@ -209,7 +209,11 @@ object GameStarter {
.sortedByDescending { it in civNamesWithStartingLocations } )
val allMercantileResources = ruleset.tileResources.values.filter { it.unique == "Can only be created by Mercantile City-States" }.map { it.name }
val allMercantileResources = ruleset.tileResources.values.filter {
it.unique == "Can only be created by Mercantile City-States" // Deprecated as of 3.16.16
|| it.uniques.contains("Can only be created by Mercantile City-States") }.map { it.name }
val unusedMercantileResources = Stack<String>()
unusedMercantileResources.addAll(allMercantileResources.shuffled())

View File

@ -273,7 +273,9 @@ class Nation : INamed, ICivilopediaText, IHasUniques {
if (showResources) {
val allMercantileResources = ruleset.tileResources.values
.filter { it.unique == "Can only be created by Mercantile City-States" }
.filter { it.unique == "Can only be created by Mercantile City-States" // Deprecated 3.16.16
|| it.uniques.contains("Can only be created by Mercantile City-States") }
if (allMercantileResources.isNotEmpty()) {
textList += FormattedLine()
textList += FormattedLine("The unique luxury is one of:")

View File

@ -84,12 +84,6 @@ class TileResource : NamedStats(), ICivilopediaText, IHasUniques {
}
}
if (unique != null) {
textList += FormattedLine()
// Marble's unique is not parameterized, so the detour through the object is only useful for mods
textList += FormattedLine(Unique(unique!!))
}
textList += Belief.getCivilopediaTextMatching(name, ruleset)
return textList