Buildings that provide free buildings (e.g. The Great Library) now deal with civ uniques (e.g. Paper Maker)
This commit is contained in:
parent
324176d098
commit
de4c042dd5
1 changed files with 10 additions and 2 deletions
|
@ -216,8 +216,16 @@ class Building : NamedStats(), IConstruction{
|
||||||
}
|
}
|
||||||
construction.addBuilding(name)
|
construction.addBuilding(name)
|
||||||
|
|
||||||
if (providesFreeBuilding != null && !construction.builtBuildings.contains(providesFreeBuilding!!))
|
if (providesFreeBuilding != null && !construction.containsBuildingOrEquivalent(providesFreeBuilding!!)) {
|
||||||
construction.addBuilding(providesFreeBuilding!!)
|
var buildingToAdd = providesFreeBuilding!!
|
||||||
|
|
||||||
|
for(building in GameBasics.Buildings.values)
|
||||||
|
if(building.replaces == buildingToAdd && building.uniqueTo==civInfo.civName)
|
||||||
|
buildingToAdd = building.name
|
||||||
|
|
||||||
|
construction.addBuilding(buildingToAdd)
|
||||||
|
}
|
||||||
|
|
||||||
when {
|
when {
|
||||||
"Empire enters golden age" in uniques-> civInfo.goldenAges.enterGoldenAge()
|
"Empire enters golden age" in uniques-> civInfo.goldenAges.enterGoldenAge()
|
||||||
"Free Great Artist Appears" in uniques-> civInfo.addGreatPerson("Great Artist")
|
"Free Great Artist Appears" in uniques-> civInfo.addGreatPerson("Great Artist")
|
||||||
|
|
Loading…
Reference in a new issue