diff --git a/core/src/com/unciv/logic/map/mapgenerator/NaturalWonderGenerator.kt b/core/src/com/unciv/logic/map/mapgenerator/NaturalWonderGenerator.kt index 6ed5eba4db..f679290e98 100644 --- a/core/src/com/unciv/logic/map/mapgenerator/NaturalWonderGenerator.kt +++ b/core/src/com/unciv/logic/map/mapgenerator/NaturalWonderGenerator.kt @@ -150,18 +150,14 @@ class NaturalWonderGenerator(val ruleset: Ruleset, val randomness: MapGeneration clearTile(location, wonder.occursOn) } - val conversionUniques = wonder.getMatchingUniques(UniqueType.NaturalWonderConvertNeighbors, StateForConditionals.IgnoreConditionals) + - wonder.getMatchingUniques(UniqueType.NaturalWonderConvertNeighborsExcept, StateForConditionals.IgnoreConditionals) + val conversionUniques = wonder.getMatchingUniques(UniqueType.NaturalWonderConvertNeighbors, StateForConditionals.IgnoreConditionals) if (conversionUniques.none()) return for (tile in location.neighbors) { val state = StateForConditionals(tile = tile) for (unique in conversionUniques) { if (!unique.conditionalsApply(state)) continue - val convertTo = if (unique.type == UniqueType.NaturalWonderConvertNeighborsExcept) { - if (tile.matchesWonderFilter(unique.params[0])) continue - unique.params[1] - } else unique.params[0] + val convertTo = unique.params[0] if (tile.baseTerrain == convertTo || convertTo in tile.terrainFeatures) continue if (convertTo == Constants.lakes && tile.isCoastalTile()) continue val terrainObject = location.ruleset.terrains[convertTo] ?: continue diff --git a/core/src/com/unciv/models/ruleset/unique/UniqueType.kt b/core/src/com/unciv/models/ruleset/unique/UniqueType.kt index 7ff66114a2..cae79a50a1 100644 --- a/core/src/com/unciv/models/ruleset/unique/UniqueType.kt +++ b/core/src/com/unciv/models/ruleset/unique/UniqueType.kt @@ -539,10 +539,6 @@ enum class UniqueType( NaturalWonderConvertNeighbors("Neighboring tiles will convert to [baseTerrain/terrainFeature]", UniqueTarget.Terrain, flags = UniqueFlag.setOfHiddenToUsers, docDescription = "Supports conditionals that need only a Tile as context and nothing else, like ``, and applies them per neighbor." + "\nIf your mod renames Coast or Lakes, do not use this with one of these as parameter, as the code preventing artifacts won't work."), - @Deprecated("As of 4.12.19", ReplaceWith("Neighboring tiles will convert to [baseTerrain/terrainFeature] ")) - NaturalWonderConvertNeighborsExcept("Neighboring tiles except [simpleTerrain] will convert to [baseTerrain/terrainFeature]", UniqueTarget.Terrain, flags = UniqueFlag.setOfHiddenToUsers, - docDescription = "Supports conditionals that need only a Tile as context and nothing else, like ``, and applies them per neighbor." + - "\nIf your mod renames Coast or Lakes, do not use this with one of these as parameter, as the code preventing artifacts won't work."), GrantsStatsToFirstToDiscover("Grants [stats] to the first civilization to discover it", UniqueTarget.Terrain), // General terrain @@ -998,6 +994,10 @@ enum class UniqueType( // endregion ///////////////////////////////////////////// region 99 DEPRECATED AND REMOVED ///////////////////////////////////////////// + @Deprecated("As of 4.12.19", ReplaceWith("Neighboring tiles will convert to [baseTerrain/terrainFeature] "), DeprecationLevel.ERROR) + NaturalWonderConvertNeighborsExcept("Neighboring tiles except [simpleTerrain] will convert to [baseTerrain/terrainFeature]", UniqueTarget.Terrain, flags = UniqueFlag.setOfHiddenToUsers, + docDescription = "Supports conditionals that need only a Tile as context and nothing else, like ``, and applies them per neighbor." + + "\nIf your mod renames Coast or Lakes, do not use this with one of these as parameter, as the code preventing artifacts won't work."), @Deprecated("As of 4.12.16", ReplaceWith("in tiles adjacent to [tileFilter] tiles"), DeprecationLevel.ERROR) ConditionalAdjacentToOld("in tiles adjacent to [tileFilter]", UniqueTarget.Conditional), @Deprecated("As of 4.12.16", ReplaceWith("in tiles not adjacent to [tileFilter] tiles"), DeprecationLevel.ERROR)