Add a persistent event log for shop and prep actions.
This commit is contained in:
@@ -35,6 +35,8 @@ type View struct {
|
||||
Pending *PendingTrade `json:"pending,omitempty"`
|
||||
Battle *BattleResult `json:"battle,omitempty"`
|
||||
WinnerSeat int `json:"winnerSeat"`
|
||||
// Log is the shared, public event log shown across every phase.
|
||||
Log []LogEntry `json:"log,omitempty"`
|
||||
// Debug is set by the server when its DEBUG flag is on, unlocking the
|
||||
// client's "buy any card" panel. Not part of the pure game state.
|
||||
Debug bool `json:"debug,omitempty"`
|
||||
@@ -54,6 +56,7 @@ func (g *Game) ViewFor(playerID string) View {
|
||||
PrioritySeat: g.PrioritySeat,
|
||||
ShopRow: g.ShopRow,
|
||||
WinnerSeat: g.WinnerSeat,
|
||||
Log: g.Log,
|
||||
}
|
||||
for _, deck := range g.ShopDecks {
|
||||
v.DeckCounts = append(v.DeckCounts, len(deck))
|
||||
|
||||
Reference in New Issue
Block a user