Documentation
¶
Overview ¶
Package core contains the main operations for the game engine
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func StartCleaner ¶
func StartCleaner()
StartCleaner starts the process that cleans up unfinished games
Types ¶
type ConnectRequest ¶
type ConnectRequest struct {
GameName string
Token string
NoOfPlayers int
PlayerName string
EventCallback *url.URL
TotalRounds int
}
ConnectRequest is the input for the Connect operation in the core
type ConnectResponse ¶
ConnectResponse is the output for the Connect operation in the core
func Connect ¶
func Connect(req ConnectRequest) (ConnectResponse, error)
Connect tries to connect a new user to a game specified by the token
type PlayRequest ¶
PlayRequest is the input for the Play operation in the core
type PlayResponse ¶
PlayResponse is the output for the Play operation in the core
func Play ¶
func Play(req PlayRequest) (PlayResponse, error)
Play processes a given player's move in a given round in a specific game
Click to show internal directories.
Click to hide internal directories.