Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Game ¶
type Game struct { ID string `json:"id"` // Channel ID Name string `name:"name"` // channel name when created StartedAt *time.Time `json:"started_at"` Players []string `json:"players"` }
func UnmarshalGameString ¶
func (*Game) MarshalGameString ¶
type GameEntry ¶
type GameEntry struct { ID string `json:"id"` GameID string `json:"game_id"` PlayerID string `json:"player_id"` Roll int `json:"roll"` AssignedTo string `json:"assigned_to"` Status string `json:"status"` // TODO: what statuses can we have? CreatedDate *time.Time `json:"created_date"` ReconciledDate *time.Time `json:"reconciled_date"` }
type Session ¶
type SessionEntry ¶
type SessionEntry struct { ID string SessionRollID string PlayerID string Roll int AssignedTo string Completed bool }
func (*SessionEntry) Complete ¶
func (se *SessionEntry) Complete()
func (*SessionEntry) IsComplete ¶
func (se *SessionEntry) IsComplete() bool
func (*SessionEntry) String ¶
func (se *SessionEntry) String() string
type SessionRoll ¶
type SessionRoll struct { ID string SessionID string Type RollType Players []*Player // players involved in this roll Entries []*SessionEntry }
func (*SessionRoll) HasPlayer ¶
func (sr *SessionRoll) HasPlayer(playerID string) *Player
func (*SessionRoll) HasPlayerEntry ¶
func (sr *SessionRoll) HasPlayerEntry(playerID string) *SessionEntry
func (*SessionRoll) IsComplete ¶
func (sr *SessionRoll) IsComplete() bool
func (*SessionRoll) IsLoser ¶
func (sr *SessionRoll) IsLoser(input *SessionEntry) bool
LoserEntires the entries that have the lowest score
Click to show internal directories.
Click to hide internal directories.