diff options
author | Joffrey Bion <joffrey.bion@booking.com> | 2020-03-30 11:30:32 +0200 |
---|---|---|
committer | Joffrey Bion <joffrey.bion@booking.com> | 2020-03-30 11:35:10 +0200 |
commit | 0ca4028cdb58cc7649da04c0c2b16479ecd83d79 (patch) | |
tree | f027e587b2c4d8d30acdb4e6205d0319fe5df9b4 /sw-common-model/src/commonMain/kotlin/org | |
parent | Rename GameState -> TableState (diff) | |
download | seven-wonders-0ca4028cdb58cc7649da04c0c2b16479ecd83d79.tar.gz seven-wonders-0ca4028cdb58cc7649da04c0c2b16479ecd83d79.tar.bz2 seven-wonders-0ca4028cdb58cc7649da04c0c2b16479ecd83d79.zip |
Send turn info without hands when entering game
Diffstat (limited to 'sw-common-model/src/commonMain/kotlin/org')
-rw-r--r-- | sw-common-model/src/commonMain/kotlin/org/luxons/sevenwonders/model/Moves.kt | 4 |
1 files changed, 4 insertions, 0 deletions
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<PlayerTurnInfo>.hideHandsAndWaitForReadiness() = + map { it.copy(action = Action.SAY_READY, hand = null) } + @Serializable data class PlayedMove( val playerIndex: Int, |