UFO: Alien Invasion
|
Serverlist menu callbacks for multiplayer. More...
#include "../../cl_shared.h"
#include "../../ui/ui_data.h"
#include "mp_callbacks.h"
#include "mp_serverlist.h"
#include "../cl_game.h"
Go to the source code of this file.
Functions | |
static void | GAME_MP_Connect_f (void) |
static void | GAME_MP_RconCallback (struct net_stream *s) |
bool | GAME_MP_Rcon (const char *password, const char *command) |
Sends an rcon command to the gameserver that the user is currently connected to, or if this is not the case, the gameserver that is specified in the cvar rcon_address. More... | |
static void | GAME_MP_Rcon_f (void) |
static void | GAME_MP_StartGame_f (void) |
static void | GAME_MP_Disconnect_f (void) |
Binding for disconnect console command. More... | |
static void | GAME_MP_Reconnect_f (void) |
The server is changing levels. More... | |
static void | GAME_MP_SelectTeam_Init_f (void) |
Send the SV_CMD_TEAMINFO command to server. More... | |
static bool | GAME_MP_SetTeamNum (int teamnum) |
static void | GAME_MP_TeamNum_f (void) |
Increase or decrease the teamnum. More... | |
static int | GAME_MP_CompleteNetworkAddress (const char *partial, const char **match) |
Autocomplete function for some network functions. More... | |
static void | GAME_MP_InitUI_f (void) |
void | GAME_MP_CallbacksInit (const cgame_import_t *import) |
void | GAME_MP_CallbacksShutdown (void) |
Variables | |
static const cgame_import_t * | cgi |
teamData_t | teamData |
cvar_t * | rcon_client_password |
cvar_t * | cl_maxsoldiersperteam |
cvar_t * | cl_maxsoldiersperplayer |
cvar_t * | cl_roundtimelimit |
static cvar_t * | rcon_address |
static cvar_t * | info_password |
static const cmdList_t | mpCallbacks [] |
Serverlist menu callbacks for multiplayer.
Definition in file mp_callbacks.cpp.
void GAME_MP_CallbacksInit | ( | const cgame_import_t * | import | ) |
Definition at line 300 of file mp_callbacks.cpp.
References CVAR_ARCHIVE, cgame_import_s::Cvar_Get(), CVAR_SERVERINFO, CVAR_USERINFO, DOUBLEQUOTE, GAME_MP_CompleteNetworkAddress(), MAX_ACTIVETEAM, and cvar_s::modified.
Referenced by GAME_MP_InitStartup().
Definition at line 318 of file mp_callbacks.cpp.
Referenced by GAME_MP_Shutdown().
|
static |
Autocomplete function for some network functions.
Definition at line 264 of file mp_callbacks.cpp.
References cgame_import_s::Cvar_GetString(), i, MAX_BOOKMARKS, and va().
Referenced by GAME_MP_CallbacksInit().
Definition at line 42 of file mp_callbacks.cpp.
References _, ca_connecting, cgame_import_s::Cmd_Argv(), DOUBLEQUOTE, MAX_VAR, serverList_s::node, PORT_SERVER, Q_strncpyz(), selectedServer, and serverList_s::service.
Binding for disconnect console command.
Definition at line 173 of file mp_callbacks.cpp.
Definition at line 277 of file mp_callbacks.cpp.
References _, cgame_import_s::csi, csi_s::gts, i, gametype_s::id, gametype_s::name, csi_s::numGTs, TEXT_LIST, and cgame_import_s::UI_AddOption().
bool GAME_MP_Rcon | ( | const char * | password, |
const char * | command | ||
) |
Sends an rcon command to the gameserver that the user is currently connected to, or if this is not the case, the gameserver that is specified in the cvar rcon_address.
true
if the command was send, false
otherwise. Definition at line 112 of file mp_callbacks.cpp.
References ca_connected, DOUBLEQUOTE, GAME_MP_RconCallback(), cgame_import_s::NET_Connect(), port, PORT_SERVER, Q_strnull(), cvar_s::string, and SV_CMD_RCON.
Referenced by GAME_MP_Rcon_f().
Send the rest of the command line over as an unconnected command.
Definition at line 146 of file mp_callbacks.cpp.
References cgame_import_s::Cmd_Args(), cgame_import_s::Cmd_Argv(), Com_Printf(), GAME_MP_Rcon(), and cvar_s::string.
|
static |
Definition at line 84 of file mp_callbacks.cpp.
References cgame_import_s::NET_ReadMsg(), Q_streq, and svc_oob.
Referenced by GAME_MP_Rcon().
The server is changing levels.
Definition at line 182 of file mp_callbacks.cpp.
References ca_connecting.
Send the SV_CMD_TEAMINFO command to server.
Definition at line 201 of file mp_callbacks.cpp.
References _, cgame_import_s::Cvar_Set(), PROTOCOL_VERSION, SV_CMD_TEAMINFO, and TEXT_STANDARD.
Referenced by GAME_MP_TeamNum_f().
|
static |
Definition at line 215 of file mp_callbacks.cpp.
References _, Com_sprintf(), DEBUG_CLIENT, MAX_VAR, teamData_s::maxPlayersPerTeam, teamData_s::teamCount, and TEXT_STANDARD.
Referenced by GAME_MP_TeamNum_f().
Definition at line 162 of file mp_callbacks.cpp.
Increase or decrease the teamnum.
Definition at line 235 of file mp_callbacks.cpp.
References cgame_import_s::Cmd_Argv(), GAME_MP_SelectTeam_Init_f(), GAME_MP_SetTeamNum(), i, teamData_s::maxteams, Q_streq, TEAM_CIVILIAN, and TEAM_DEFAULT.
|
static |
Definition at line 32 of file mp_callbacks.cpp.
cvar_t* cl_maxsoldiersperplayer |
Definition at line 37 of file mp_callbacks.cpp.
Referenced by GAME_MP_RunFrame(), and GAME_MP_StartServer_f().
cvar_t* cl_maxsoldiersperteam |
Definition at line 36 of file mp_callbacks.cpp.
Referenced by GAME_MP_RunFrame(), and GAME_MP_StartServer_f().
cvar_t* cl_roundtimelimit |
Definition at line 38 of file mp_callbacks.cpp.
Referenced by GAME_MP_RunFrame().
|
static |
Definition at line 40 of file mp_callbacks.cpp.
|
static |
Definition at line 287 of file mp_callbacks.cpp.
|
static |
Definition at line 39 of file mp_callbacks.cpp.
cvar_t* rcon_client_password |
Definition at line 35 of file mp_callbacks.cpp.
Referenced by GAME_MP_RunFrame(), and GAME_MP_StartBattlescape().
teamData_t teamData |
Definition at line 34 of file mp_callbacks.cpp.
Referenced by GAME_MP_ParseTeamInfoMessage(), and GAME_MP_Shutdown().