mirror of
https://github.com/yairm210/Unciv.git
synced 2025-07-16 02:40:41 +07:00
Solved crash for badly defined mods like REKmod
This commit is contained in:
@ -230,7 +230,8 @@ open class TileInfo {
|
||||
val resource = getTileResource()
|
||||
stats.add(getTileResource()) // resource base
|
||||
if (resource.building != null && city != null && city.cityConstructions.isBuilt(resource.building!!)) {
|
||||
val resourceBuilding = tileMap.gameInfo.ruleSet.buildings[resource.building!!]!!
|
||||
val resourceBuilding = tileMap.gameInfo.ruleSet.buildings[resource.building!!]
|
||||
if (resourceBuilding != null && resourceBuilding.resourceBonusStats != null)
|
||||
stats.add(resourceBuilding.resourceBonusStats!!) // resource-specific building (eg forge, stable) bonus
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user