From 0ca4028cdb58cc7649da04c0c2b16479ecd83d79 Mon Sep 17 00:00:00 2001 From: Joffrey Bion Date: Mon, 30 Mar 2020 11:30:32 +0200 Subject: Send turn info without hands when entering game --- .../src/commonMain/kotlin/org/luxons/sevenwonders/model/Moves.kt | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'sw-common-model/src/commonMain/kotlin') diff --git a/sw-common-model/src/commonMain/kotlin/org/luxons/sevenwonders/model/Moves.kt b/sw-common-model/src/commonMain/kotlin/org/luxons/sevenwonders/model/Moves.kt index d684505e..736ace86 100644 --- a/sw-common-model/src/commonMain/kotlin/org/luxons/sevenwonders/model/Moves.kt +++ b/sw-common-model/src/commonMain/kotlin/org/luxons/sevenwonders/model/Moves.kt @@ -30,6 +30,10 @@ data class PlayerTurnInfo( val wonderBuildability: WonderBuildability = table.boards[playerIndex].wonder.buildability } +// TODO move to server code +fun Collection.hideHandsAndWaitForReadiness() = + map { it.copy(action = Action.SAY_READY, hand = null) } + @Serializable data class PlayedMove( val playerIndex: Int, -- cgit