Maps no longer spawn ancient ruins in immediate vicinity of civ spawns

This commit is contained in:
Yair Morgenstern 2020-05-03 21:45:23 +03:00
parent ad7d7fba60
commit d828fdaeca

View file

@ -129,10 +129,11 @@ object GameStarter {
for (civ in gameInfo.civilizations.filter { !it.isBarbarian() }) {
val startingLocation = startingLocations[civ]!!
for (tile in startingLocation.getTilesInDistance(3))
tile.improvement = null // Remove ancient ruins in immediate vicinity
fun placeNearStartingPosition(unitName:String) {
val newUnit = civ.placeUnitNearTile(startingLocation.position, unitName)
if (newUnit != null) newUnit.currentTile.improvement = null
fun placeNearStartingPosition(unitName: String) {
civ.placeUnitNearTile(startingLocation.position, unitName)
}
placeNearStartingPosition(Constants.settler)
placeNearStartingPosition(getWarriorEquivalent(civ))
@ -144,7 +145,6 @@ object GameStarter {
}
}
}
}
private fun getStartingLocations(civs: List<CivilizationInfo>, tileMap: TileMap): HashMap<CivilizationInfo, TileInfo> {