Add points to player info
This commit is contained in:
parent
7ac0f29904
commit
86456b2441
@ -1,8 +1,8 @@
|
||||
import Foundation
|
||||
|
||||
enum SupportedLanguage {
|
||||
case german
|
||||
case english
|
||||
enum SupportedLanguage: String, Codable {
|
||||
case german = "german"
|
||||
case english = "english"
|
||||
|
||||
var gameSummarizer: GameSummarizer.Type {
|
||||
switch self {
|
||||
|
@ -5,6 +5,8 @@ struct PlayerInfo: Codable, Equatable {
|
||||
/// The name of the player
|
||||
let name: PlayerName
|
||||
|
||||
var points = 0
|
||||
|
||||
/// Indicates that the player is active, i.e. a session is established
|
||||
var isConnected = false
|
||||
|
||||
@ -31,6 +33,7 @@ struct PlayerInfo: Codable, Equatable {
|
||||
/// Convert the property names into shorter strings for JSON encoding
|
||||
enum CodingKeys: String, CodingKey {
|
||||
case name = "name"
|
||||
case points = "points"
|
||||
case isConnected = "connected"
|
||||
case isNextActor = "active"
|
||||
case playedCard = "card"
|
||||
|
Loading…
Reference in New Issue
Block a user