mirror of
https://github.com/yairm210/Unciv.git
synced 2025-07-12 16:59:11 +07:00
Resolved #2907 - University unique registers properly
This commit is contained in:
@ -159,8 +159,8 @@
|
|||||||
{
|
{
|
||||||
"name": "Organized Religion",
|
"name": "Organized Religion",
|
||||||
"effect": "+1 happiness for each monument, temple and monastery",
|
"effect": "+1 happiness for each monument, temple and monastery",
|
||||||
"uniques": ["[+1 happiness] from every [Monument]","[+1 happiness] from every [Temple]",
|
"uniques": ["[+1 Happiness] from every [Monument]","[+1 Happiness] from every [Temple]",
|
||||||
"[+1 happiness] from every [Monastery]"]
|
"[+1 Happiness] from every [Monastery]"]
|
||||||
"row": 1,
|
"row": 1,
|
||||||
"column": 2
|
"column": 2
|
||||||
},
|
},
|
||||||
|
@ -172,14 +172,6 @@ open class TileInfo {
|
|||||||
fun getTileStats(city: CityInfo?, observingCiv: CivilizationInfo): Stats {
|
fun getTileStats(city: CityInfo?, observingCiv: CivilizationInfo): Stats {
|
||||||
var stats = getBaseTerrain().clone()
|
var stats = getBaseTerrain().clone()
|
||||||
|
|
||||||
if(city!=null) for(unique in city.getBuildingUniques()) {
|
|
||||||
if (unique.equalsPlaceholderText("[] from [] tiles")) {
|
|
||||||
val placeholderParams = unique.getPlaceholderParameters()
|
|
||||||
val tileType = placeholderParams[1]
|
|
||||||
if (baseTerrain == tileType || terrainFeature == tileType || resource == tileType || improvement == tileType)
|
|
||||||
stats.add(Stats.parse(placeholderParams[0]))
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
if (terrainFeature != null) {
|
if (terrainFeature != null) {
|
||||||
val terrainFeatureBase = getTerrainFeature()
|
val terrainFeatureBase = getTerrainFeature()
|
||||||
@ -189,6 +181,15 @@ open class TileInfo {
|
|||||||
stats.add(terrainFeatureBase)
|
stats.add(terrainFeatureBase)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if(city!=null) for(unique in city.getBuildingUniques()) {
|
||||||
|
if (unique.equalsPlaceholderText("[] from [] tiles")) {
|
||||||
|
val placeholderParams = unique.getPlaceholderParameters()
|
||||||
|
val tileType = placeholderParams[1]
|
||||||
|
if (baseTerrain == tileType || terrainFeature == tileType || resource == tileType || improvement == tileType)
|
||||||
|
stats.add(Stats.parse(placeholderParams[0]))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
if (naturalWonder != null) {
|
if (naturalWonder != null) {
|
||||||
val wonder = getNaturalWonder()
|
val wonder = getNaturalWonder()
|
||||||
stats.add(wonder)
|
stats.add(wonder)
|
||||||
|
Reference in New Issue
Block a user