server: now idle response timeout will be disabled in local games with 1 human player

This commit is contained in:
Oleg Agafonov 2024-09-21 14:45:48 +04:00
parent 291a28d1db
commit 7d1ab71092

View file

@ -96,7 +96,7 @@ public class GameController implements GameCallback {
this.tableId = tableId; this.tableId = tableId;
this.choosingPlayerId = choosingPlayerId; this.choosingPlayerId = choosingPlayerId;
this.gameOptions = gameOptions; this.gameOptions = gameOptions;
this.useResponseIdleTimeout = game.getPlayers().values().stream().anyMatch(Player::isHuman); this.useResponseIdleTimeout = game.getPlayers().values().stream().filter(Player::isHuman).count() > 1;
init(); init();
} }