Singleplayer campaign game type headers. More...
#include "ui/ui_nodes.h"
Go to the source code of this file.
Functions | |
void | GAME_CP_DisplayItemInfo (uiNode_t *node, const char *string) |
const mapDef_t * | GAME_CP_MapInfo (int step) |
void | GAME_CP_InitStartup (void) |
void | GAME_CP_Shutdown (void) |
qboolean | GAME_CP_ItemIsUseable (const objDef_t *od) |
void | GAME_CP_Results (struct dbuffer *msg, int winner, int *numSpawned, int *numAlive, int numKilled[][MAX_TEAMS], int numStunned[][MAX_TEAMS]) |
After a mission was finished this function is called. | |
qboolean | GAME_CP_Spawn (void) |
int | GAME_CP_GetTeam (void) |
equipDef_t * | GAME_CP_GetEquipmentDefinition (void) |
void | GAME_CP_CharacterCvars (const character_t *chr) |
qboolean | GAME_CP_TeamIsKnown (const teamDef_t *teamDef) |
Checks whether the team is known at this stage already. | |
void | GAME_CP_Drop (void) |
void | GAME_CP_InitializeBattlescape (const chrList_t *team) |
Changes some actor states for a campaign game. | |
void | GAME_CP_Frame (void) |
const char * | GAME_CP_GetModelForItem (const objDef_t *od) |
Sets the item model for an object assigned technology. If no technology is set or the technology has no model assigned, this function is returning NULL to tell the caller to use the default object model. |
Singleplayer campaign game type headers.
Definition in file cl_game_campaign.h.
void GAME_CP_CharacterCvars | ( | const character_t * | chr | ) |
Definition at line 450 of file cl_game_campaign.c.
References _, chrScoreGlobal_s::assignedMissions, CL_GetRankByIdx(), Com_sprintf(), Cvar_Set(), rank_s::image, KILLED_CIVILIANS, KILLED_ENEMIES, KILLED_TEAM, chrScoreGlobal_s::kills, MAX_VAR, rank_s::name, chrScoreGlobal_s::rank, character_s::score, and va().
void GAME_CP_DisplayItemInfo | ( | uiNode_t * | node, | |
const char * | string | |||
) |
Definition at line 470 of file cl_game_campaign.c.
References AIR_GetAircraftSilent(), Com_Printf(), technology_s::mdl, RS_GetTechByProvided(), aircraft_s::tech, and UI_DrawModelNode().
void GAME_CP_Drop | ( | void | ) |
Definition at line 386 of file cl_game_campaign.c.
References CL_Disconnect(), qfalse, qtrue, SV_Shutdown(), and UI_InitStack().
void GAME_CP_Frame | ( | void | ) |
Definition at line 395 of file cl_game_campaign.c.
References CL_CampaignRun(), cls, key_console, and client_static_s::keyDest.
equipDef_t* GAME_CP_GetEquipmentDefinition | ( | void | ) |
Definition at line 445 of file cl_game_campaign.c.
References ccs, and ccs_s::eMission.
const char* GAME_CP_GetModelForItem | ( | const objDef_t * | od | ) |
Sets the item model for an object assigned technology. If no technology is set or the technology has no model assigned, this function is returning NULL
to tell the caller to use the default object model.
[in] | od | The object definition to get the model from. |
[out] | menuModel | The menu model pointer. |
NULL
. Definition at line 413 of file cl_game_campaign.c.
References technology_s::mdl, and RS_GetTechForItem().
int GAME_CP_GetTeam | ( | void | ) |
Definition at line 364 of file cl_game_campaign.c.
References ccs, ccs_s::curCampaign, and campaign_s::team.
void GAME_CP_InitializeBattlescape | ( | const chrList_t * | team | ) |
Changes some actor states for a campaign game.
team | The team to change the states for |
Definition at line 428 of file cl_game_campaign.c.
References chr_list_s::chr, clc_initactorstates, cls, i, NET_WriteByte(), NET_WriteMsg(), NET_WriteShort(), client_static_s::netStream, new_dbuffer(), chr_list_s::num, character_s::state, and character_s::ucn.
void GAME_CP_InitStartup | ( | void | ) |
Definition at line 485 of file cl_game_campaign.c.
References CL_ReadSinglePlayerData(), CL_ResetSinglePlayerData(), Cmd_AddCommand(), cp_campaign, CP_InitStartup(), cp_start_employees, CVAR_ARCHIVE, Cvar_ForceSet(), Cvar_Get(), GAME_CP_CampaignListClick_f(), GAME_CP_GetCampaigns_f(), GAME_CP_MissionAutoCheck_f(), GAME_CP_MissionAutoGo_f(), GAME_CP_Results_f(), and GAME_CP_Start_f().
Definition at line 358 of file cl_game_campaign.c.
References RS_GetTechForItem(), and RS_IsResearched_ptr().
const mapDef_t* GAME_CP_MapInfo | ( | int | step | ) |
Definition at line 353 of file cl_game_campaign.c.
References cls, Com_GetMapDefByIDX(), and client_static_s::currentSelectedMap.
void GAME_CP_Results | ( | struct dbuffer * | msg, | |
int | winner, | |||
int * | numSpawned, | |||
int * | numAlive, | |||
int | numKilled[][MAX_TEAMS], | |||
int | numStunned[][MAX_TEAMS] | |||
) |
After a mission was finished this function is called.
msg | The network message buffer | |
winner | The winning team | |
numSpawned | The amounts of all spawned actors per team | |
numAlive | The amount of survivors per team | |
numKilled | The amount of killed actors for all teams. The first dimension contains the attacker team, the second the victim team | |
numStunned | The amount of stunned actors for all teams. The first dimension contains the attacker team, the second the victim team |
Definition at line 246 of file cl_game_campaign.c.
References AII_CollectingItems(), AL_CollectingAliens(), missionResults_s::aliensKilled, ccs_s::aliensKilled, missionResults_s::aliensStunned, missionResults_s::aliensSurvived, ccs, missionResults_s::civiliansKilled, missionResults_s::civiliansKilledFriendlyFire, missionResults_s::civiliansSurvived, CL_Disconnect(), cls, CP_ExecuteMissionTrigger(), CP_InitMissionResults(), CP_ParseCharacterData(), i, ccs_s::missionAircraft, ccs_s::missionResults, missionResults_s::ownKilled, missionResults_s::ownKilledFriendlyFire, missionResults_s::ownStunned, missionResults_s::ownSurvived, qfalse, qtrue, ccs_s::selectedMission, SV_Shutdown(), client_static_s::team, TEAM_CIVILIAN, UI_InitStack(), and UI_PushWindow().
void GAME_CP_Shutdown | ( | void | ) |
Definition at line 507 of file cl_game_campaign.c.
References CL_ResetSinglePlayerData(), Cmd_RemoveCommand(), CP_CampaignExit(), qfalse, and SV_Shutdown().
qboolean GAME_CP_Spawn | ( | void | ) |
Definition at line 326 of file cl_game_campaign.c.
References aircraft_s::acTeam, ccs, employee_s::chr, cl, CL_CleanTempInventory(), linkedList_s::data, aircraft_s::homebase, ccs_s::missionAircraft, mn_hud, linkedList_s::next, qfalse, qtrue, cvar_s::string, and UI_InitStack().
Checks whether the team is known at this stage already.
[in] | teamDef | The team definition of the alien team |
true
if known, false
otherwise. Definition at line 375 of file cl_game_campaign.c.
References ccs, CHRSH_IsTeamDefAlien(), Com_Error(), ERR_DROP, teamDef_s::id, teamDef_s::idx, qtrue, RS_IsResearched_ptr(), and ccs_s::teamDefTechs.