mirror of
https://github.com/yairm210/Unciv.git
synced 2025-07-24 22:59:34 +07:00
Resolved #1252 - Tiles created inside your borders take control of the city center tile, so they don't become "Invisible cities"
This commit is contained in:
@ -72,12 +72,17 @@ class CityExpansionManager {
|
|||||||
|
|
||||||
//region state-changing functions
|
//region state-changing functions
|
||||||
fun reset() {
|
fun reset() {
|
||||||
for(tile in cityInfo.tiles.map { cityInfo.tileMap[it] })
|
for(tile in cityInfo.getTiles())
|
||||||
relinquishOwnership(tile)
|
relinquishOwnership(tile)
|
||||||
|
|
||||||
cityInfo.getCenterTile().getTilesInDistance(1)
|
cityInfo.getCenterTile().getTilesInDistance(1)
|
||||||
.filter { it.getCity()==null } // can't take ownership of owned tiles
|
.filter { it.getCity()==null } // can't take ownership of owned tiles (by other cities)
|
||||||
.forEach { takeOwnership(it) }
|
.forEach { takeOwnership(it) }
|
||||||
|
|
||||||
|
// The only way to create a city inside an owned tile is if it's in your territory
|
||||||
|
// In this case, if you don't assign control of the central tile to the city,
|
||||||
|
// It becomes an invisible city and weird shit starts happening
|
||||||
|
takeOwnership(cityInfo.getCenterTile())
|
||||||
}
|
}
|
||||||
|
|
||||||
private fun addNewTileWithCulture() {
|
private fun addNewTileWithCulture() {
|
||||||
|
Reference in New Issue
Block a user