quarkshologridledger/tongo-core/internal/domain/entity/match.go

43 lines
1.3 KiB
Go

package entity
// MatchStatus represents the lifecycle phase of a match.
type MatchStatus string
const (
MatchStatusScheduled MatchStatus = "SCHEDULED"
MatchStatusPreMatch MatchStatus = "PRE_MATCH"
MatchStatusLive MatchStatus = "LIVE"
MatchStatusResolving MatchStatus = "RESOLVING"
MatchStatusSettled MatchStatus = "SETTLED"
)
// Match represents a live engagement between two factions at a venue.
type Match struct {
ID string `json:"id"`
Name string `json:"name"`
Quadrant string `json:"quadrant"`
Status MatchStatus `json:"status"`
Tick int `json:"tick"`
MaxTicks int `json:"maxTicks"`
KineticYield float64 `json:"kinetic_yield"`
Venue Venue `json:"venue"`
Factions MatchFactions `json:"factions"`
Markets []Market `json:"markets"`
RecentEvents []MatchEvent `json:"recentEvents"`
}
// MatchFactions holds the two competing factions.
type MatchFactions struct {
Home FactionState `json:"home"`
Away FactionState `json:"away"`
}
// TickResult captures the outcome of a single combat tick.
type TickResult struct {
HomeDamageDealt float64
AwayDamageDealt float64
HomeShieldsAfter float64
AwayShieldsAfter float64
KineticYieldDelta float64
EventsFired []MatchEvent
}