hooks

package
v0.0.0-...-b729ba2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 30, 2016 License: GPL-3.0 Imports: 16 Imported by: 0

Documentation

Overview

Package hooks contains event hooks, which are called after specific events, like lobby joins and logins.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AfterConnect

func AfterConnect(server *wsevent.Server, so *wsevent.Client)

func AfterConnectLoggedIn

func AfterConnectLoggedIn(so *wsevent.Client, player *player.Player)

func AfterLobbyJoin

func AfterLobbyJoin(so *wsevent.Client, lob *lobby.Lobby, player *player.Player)

func AfterLobbyLeave

func AfterLobbyLeave(lob *lobby.Lobby, player *player.Player, kicked bool, notReady bool)

func AfterLobbySpec

func AfterLobbySpec(server *wsevent.Server, so *wsevent.Client, player *player.Player, lob *lobby.Lobby)

func AfterLobbySpecLeave

func AfterLobbySpecLeave(so *wsevent.Client, lob *lobby.Lobby)

func BroadcastLobbyStart

func BroadcastLobbyStart(lob *lobby.Lobby)

Not really broadcast, since it sends each client a different LobbyStart JSON

func GetLobbyRoom

func GetLobbyRoom(lobbyid uint) string

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.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL