using System; using System.Collections.Generic; using Newtonsoft.Json; using CommanderAILab.UI; namespace CommanderAILab.Models { /// Full live game state snapshot pushed by the server on state_update events. [Serializable] public class GameState { [JsonProperty("seats")] public List seats; [JsonProperty("active_seat")] public int activeSeat; [JsonProperty("turn_number")] public int turnNumber; [JsonProperty("phase")] public string phase; [JsonProperty("stack")] public List stack; } /// Per-seat state within a GameState snapshot. [Serializable] public class SeatState { [JsonProperty("seat_index")] public int seatIndex; [JsonProperty("player_name")] public string playerName; [JsonProperty("life")] public int life; [JsonProperty("hand")] public List hand; [JsonProperty("battlefield")] public List battlefield; [JsonProperty("graveyard")] public List graveyard; [JsonProperty("exile")] public List exile; [JsonProperty("commander")] public CardModel commander; [JsonProperty("commander_cast_count")] public int commanderCastCount; /// Cumulative commander damage received from each seat index (length 4). [JsonProperty("commander_damage_from")] public int[] commanderDamageFrom; [JsonProperty("poison_counters")] public int poisonCounters; [JsonProperty("mana_pool")] public Dictionary manaPool; [JsonProperty("is_eliminated")] public bool isEliminated; } }