diff options
Diffstat (limited to 'sw-common-model/src')
-rw-r--r-- | sw-common-model/src/commonMain/kotlin/org/luxons/sevenwonders/model/api/Api.kt | 5 | ||||
-rw-r--r-- | sw-common-model/src/commonMain/kotlin/org/luxons/sevenwonders/model/api/actions/Actions.kt | 11 |
2 files changed, 14 insertions, 2 deletions
diff --git a/sw-common-model/src/commonMain/kotlin/org/luxons/sevenwonders/model/api/Api.kt b/sw-common-model/src/commonMain/kotlin/org/luxons/sevenwonders/model/api/Api.kt index 7fe266b9..7a337f9a 100644 --- a/sw-common-model/src/commonMain/kotlin/org/luxons/sevenwonders/model/api/Api.kt +++ b/sw-common-model/src/commonMain/kotlin/org/luxons/sevenwonders/model/api/Api.kt @@ -1,6 +1,7 @@ package org.luxons.sevenwonders.model.api import kotlinx.serialization.Serializable +import org.luxons.sevenwonders.model.api.actions.Icon const val SEVEN_WONDERS_WS_ENDPOINT = "/seven-wonders-websocket" @@ -46,13 +47,15 @@ data class Actionability( @Serializable data class ConnectedPlayer( val username: String, - val displayName: String + val displayName: String, + val icon: Icon? ) @Serializable data class PlayerDTO( val username: String, val displayName: String, + val icon: Icon?, val index: Int, val isGameOwner: Boolean, val isReady: Boolean diff --git a/sw-common-model/src/commonMain/kotlin/org/luxons/sevenwonders/model/api/actions/Actions.kt b/sw-common-model/src/commonMain/kotlin/org/luxons/sevenwonders/model/api/actions/Actions.kt index a4467667..0687e968 100644 --- a/sw-common-model/src/commonMain/kotlin/org/luxons/sevenwonders/model/api/actions/Actions.kt +++ b/sw-common-model/src/commonMain/kotlin/org/luxons/sevenwonders/model/api/actions/Actions.kt @@ -12,7 +12,16 @@ class ChooseNameAction( /** * The display name of the player. May contain spaces and special characters. */ - val playerName: String + val playerName: String, + /** + * The player's icon. + */ + val icon: Icon? +) + +@Serializable +data class Icon( + val name: String ) /** |