mirror of
https://github.com/yairm210/Unciv.git
synced 2025-07-15 10:18:26 +07:00
@ -252,6 +252,10 @@ class GameInfo : IsPartOfGameInfoSerialization, HasGameInfoSerializationVersion
|
|||||||
//endregion
|
//endregion
|
||||||
//region State changing functions
|
//region State changing functions
|
||||||
|
|
||||||
|
// Do we automatically simulate until N turn?
|
||||||
|
fun isSimulation(): Boolean = turns < UncivGame.Current.simulateUntilTurnForDebug
|
||||||
|
|| turns < simulateMaxTurns && simulateUntilWin
|
||||||
|
|
||||||
fun nextTurn() {
|
fun nextTurn() {
|
||||||
|
|
||||||
var player = currentPlayerCiv
|
var player = currentPlayerCiv
|
||||||
@ -278,13 +282,11 @@ class GameInfo : IsPartOfGameInfoSerialization, HasGameInfoSerializationVersion
|
|||||||
setNextPlayer()
|
setNextPlayer()
|
||||||
}
|
}
|
||||||
|
|
||||||
// Do we automatically simulate until N turn?
|
|
||||||
val isSimulation = turns < UncivGame.Current.simulateUntilTurnForDebug
|
|
||||||
|| turns < simulateMaxTurns && simulateUntilWin
|
|
||||||
val isOnline = gameParameters.isOnlineMultiplayer
|
val isOnline = gameParameters.isOnlineMultiplayer
|
||||||
|
|
||||||
// We process player automatically if:
|
// We process player automatically if:
|
||||||
while (isSimulation || // simulation is active
|
while (isSimulation() || // simulation is active
|
||||||
player.isAI() || // or player is AI
|
player.isAI() || // or player is AI
|
||||||
isOnline && (player.isDefeated() || // or player is online defeated
|
isOnline && (player.isDefeated() || // or player is online defeated
|
||||||
player.isSpectator())) // or player is online spectator
|
player.isSpectator())) // or player is online spectator
|
||||||
|
Reference in New Issue
Block a user