Fixed replacing obsolete units for new queue
This commit is contained in:
parent
6635ed5be9
commit
1b4cd9c3b3
1 changed files with 1 additions and 1 deletions
|
@ -260,7 +260,7 @@ class TechManager {
|
|||
for (city in civInfo.cities)
|
||||
for(constructionName in city.cityConstructions.constructionQueue.toList()){ // copy, since we're changing the queue
|
||||
if(constructionName !in obsoleteUnits) continue
|
||||
val constructionUnit = city.cityConstructions.getCurrentConstruction() as BaseUnit
|
||||
val constructionUnit = city.cityConstructions.getConstruction(constructionName) as BaseUnit
|
||||
city.cityConstructions.constructionQueue.replaceAll { if(it==constructionName) constructionUnit.upgradesTo!! else it }
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue