Handles callbacks from the server. More...
#include <CallBackManager.h>
Public Member Functions | |
CallBackManager (Config *configPtr, GbxRemote *serverPtr, CommandManager *commandManagerPtr, EventManager *eventManagerPtr, sql::Connection *databasePtr, std::map< std::string, Player > *playerList, MapList *mapList, ServerInfo *serverInfoPtr) | |
void | HandleCallBack (std::string methodName, std::vector< GbxResponseParameter > parameters) |
Handles callback (updates lists, calls plugin functions). More... | |
void | HandlePlayerConnect (std::vector< GbxResponseParameter > parameters) |
Handles PlayerConnect callback. More... | |
void | HandlePlayerDisconnect (std::vector< GbxResponseParameter > parameters) |
Handles PlayerDisconnect callback. More... | |
void | HandlePlayerChat (std::vector< GbxResponseParameter > parameters) |
Handles PlayerChat callback. More... | |
void | HandlePlayerManialinkPageAnswer (std::vector< GbxResponseParameter > parameters) |
Handles PlayerManialinkPageAnswer callback. More... | |
void | HandleEcho (std::vector< GbxResponseParameter > parameters) |
Handles Echo callback. More... | |
void | HandleBeginMatch (std::vector< GbxResponseParameter > parameters) |
Handles BeginMatch callback. More... | |
void | HandleEndMatch (std::vector< GbxResponseParameter > parameters) |
Handles EndMatch callback. More... | |
void | HandleBeginMap (std::vector< GbxResponseParameter > parameters) |
Handles BeginMap callback. More... | |
void | HandleEndMap (std::vector< GbxResponseParameter > parameters) |
Handles EndMap callback. More... | |
void | HandleStatusChanged (std::vector< GbxResponseParameter > parameters) |
Handles StatusChanged callback. More... | |
void | HandlePlayerCheckpoint (std::vector< GbxResponseParameter > parameters) |
Handles PlayerCheckpoint callback. More... | |
void | HandlePlayerFinish (std::vector< GbxResponseParameter > parameters) |
Handles PlayerFinish callback. More... | |
void | HandlePlayerIncoherence (std::vector< GbxResponseParameter > parameters) |
Handles PlayerIncoherence callback. More... | |
void | HandleBillUpdated (std::vector< GbxResponseParameter > parameters) |
Handles BillUpdated callback. More... | |
void | HandleMapListModified (std::vector< GbxResponseParameter > parameters) |
Handles MapListModified callback. More... | |
void | HandlePlayerInfoChanged (std::vector< GbxResponseParameter > parameters) |
Handles PlayerInfoChanged callback. More... | |
void | HandleVoteUpdated (std::vector< GbxResponseParameter > parameters) |
Handles VoteUpdated callback. More... | |
Private Attributes | |
Config * | config |
Contains the configuration. | |
GbxRemote * | server |
Contains the serverconnection. | |
CommandManager * | commands |
Contains the command manager. | |
EventManager * | events |
Contains the event manager. | |
sql::Connection * | database |
Contains the database connection. | |
std::map< std::string, Player > * | players |
Contains the list of players currently on the server. | |
MapList * | maps |
Contains the list of players currently on the server. | |
ServerInfo * | serverInfo |
Contains the server information. | |
Handles callbacks from the server.
CallBackManager::CallBackManager | ( | Config * | configPtr, |
GbxRemote * | serverPtr, | ||
CommandManager * | commandManagerPtr, | ||
EventManager * | eventManagerPtr, | ||
sql::Connection * | databasePtr, | ||
std::map< std::string, Player > * | playerList, | ||
MapList * | mapList, | ||
ServerInfo * | serverInfoPtr | ||
) |
Constructor takes pointers to playerlist and maplist to keep them updated.
configPtr | Pointer to the Config. |
serverPtr | Pointer to the GbxRemote. |
commandManagerPtr | Pointer to the CommandManager. |
eventManagerPtr | Pointer to the EventManager. |
databasePtr | Pointer to the database connection. |
playerList | Pointer to playerlist. |
mapList | Pointer to maplist. |
serverInfoPtr | Pointer to server information. |
void CallBackManager::HandleBeginMap | ( | std::vector< GbxResponseParameter > | parameters | ) |
Handles BeginMap callback.
parameters | List with method parameters. |
void CallBackManager::HandleBeginMatch | ( | std::vector< GbxResponseParameter > | parameters | ) |
Handles BeginMatch callback.
parameters | List with method parameters. |
void CallBackManager::HandleBillUpdated | ( | std::vector< GbxResponseParameter > | parameters | ) |
Handles BillUpdated callback.
parameters | List with method parameters. |
void CallBackManager::HandleCallBack | ( | std::string | methodName, |
std::vector< GbxResponseParameter > | parameters | ||
) |
Handles callback (updates lists, calls plugin functions).
methodName | Name of the callback method. |
parameters | List with method parameters. |
void CallBackManager::HandleEcho | ( | std::vector< GbxResponseParameter > | parameters | ) |
Handles Echo callback.
parameters | List with method parameters. |
void CallBackManager::HandleEndMap | ( | std::vector< GbxResponseParameter > | parameters | ) |
Handles EndMap callback.
parameters | List with method parameters. |
void CallBackManager::HandleEndMatch | ( | std::vector< GbxResponseParameter > | parameters | ) |
Handles EndMatch callback.
parameters | List with method parameters. |
void CallBackManager::HandleMapListModified | ( | std::vector< GbxResponseParameter > | parameters | ) |
Handles MapListModified callback.
parameters | List with method parameters. |
void CallBackManager::HandlePlayerChat | ( | std::vector< GbxResponseParameter > | parameters | ) |
Handles PlayerChat callback.
parameters | List with method parameters. |
void CallBackManager::HandlePlayerCheckpoint | ( | std::vector< GbxResponseParameter > | parameters | ) |
Handles PlayerCheckpoint callback.
parameters | List with method parameters. |
void CallBackManager::HandlePlayerConnect | ( | std::vector< GbxResponseParameter > | parameters | ) |
Handles PlayerConnect callback.
parameters | List with method parameters. |
void CallBackManager::HandlePlayerDisconnect | ( | std::vector< GbxResponseParameter > | parameters | ) |
Handles PlayerDisconnect callback.
parameters | List with method parameters. |
void CallBackManager::HandlePlayerFinish | ( | std::vector< GbxResponseParameter > | parameters | ) |
Handles PlayerFinish callback.
parameters | List with method parameters. |
void CallBackManager::HandlePlayerIncoherence | ( | std::vector< GbxResponseParameter > | parameters | ) |
Handles PlayerIncoherence callback.
parameters | List with method parameters. |
void CallBackManager::HandlePlayerInfoChanged | ( | std::vector< GbxResponseParameter > | parameters | ) |
Handles PlayerInfoChanged callback.
parameters | List with method parameters. |
void CallBackManager::HandlePlayerManialinkPageAnswer | ( | std::vector< GbxResponseParameter > | parameters | ) |
Handles PlayerManialinkPageAnswer callback.
parameters | List with method parameters. |
void CallBackManager::HandleStatusChanged | ( | std::vector< GbxResponseParameter > | parameters | ) |
Handles StatusChanged callback.
parameters | List with method parameters. |
void CallBackManager::HandleVoteUpdated | ( | std::vector< GbxResponseParameter > | parameters | ) |
Handles VoteUpdated callback.
parameters | List with method parameters. |