Documentation ¶
Overview ¶
Package hooks contains event hooks, which are called after specific events, like lobby joins and logins.
Index ¶
- func AfterConnect(server *wsevent.Server, so *wsevent.Client)
- func AfterConnectLoggedIn(so *wsevent.Client, player *player.Player)
- func AfterLobbyJoin(so *wsevent.Client, lob *lobby.Lobby, player *player.Player)
- func AfterLobbyLeave(lob *lobby.Lobby, player *player.Player, kicked bool, notReady bool)
- func AfterLobbySpec(server *wsevent.Server, so *wsevent.Client, player *player.Player, ...)
- func AfterLobbySpecLeave(so *wsevent.Client, lob *lobby.Lobby)
- func BroadcastLobbyStart(lob *lobby.Lobby)
- func GetLobbyRoom(lobbyid uint) string
- func OnDisconnect(socketID string, token *jwt.Token)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AfterLobbyJoin ¶
func AfterLobbyLeave ¶
func AfterLobbySpec ¶
func BroadcastLobbyStart ¶
Not really broadcast, since it sends each client a different LobbyStart JSON
func GetLobbyRoom ¶
func OnDisconnect ¶
func OnDisconnect(socketID string, token *jwt.Token)
OnDisconnect is connected when a player with a given socketID disconnects
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.