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