mirror of
https://github.com/yairm210/Unciv.git
synced 2025-07-14 09:48:12 +07:00
check whether the city has been a puppet in "Pick construction" action. (#7963)
This commit is contained in:
@ -672,10 +672,16 @@ class WorldScreen(
|
||||
viewingCiv.shouldGoToDueUnit() ->
|
||||
NextTurnAction("Next unit", Color.LIGHT_GRAY) { switchToNextUnit() }
|
||||
|
||||
viewingCiv.cities.any { it.cityConstructions.currentConstructionFromQueue == "" } ->
|
||||
viewingCiv.cities.any {
|
||||
!it.isPuppet &&
|
||||
it.cityConstructions.currentConstructionFromQueue == ""
|
||||
} ->
|
||||
NextTurnAction("Pick construction", Color.CORAL) {
|
||||
val cityWithNoProductionSet = viewingCiv.cities
|
||||
.firstOrNull { it.cityConstructions.currentConstructionFromQueue == "" }
|
||||
.firstOrNull {
|
||||
!it.isPuppet &&
|
||||
it.cityConstructions.currentConstructionFromQueue == ""
|
||||
}
|
||||
if (cityWithNoProductionSet != null) game.pushScreen(
|
||||
CityScreen(cityWithNoProductionSet)
|
||||
)
|
||||
|
Reference in New Issue
Block a user