|
UFO: Alien Invasion
|

Go to the source code of this file.
Data Structures | |
| struct | chrTemplate_t |
| struct | chrScoreMission_t |
| Structure of all stats collected in a mission. More... | |
| struct | chrScoreGlobal_t |
| Structure of all stats collected for an actor over time. More... | |
| class | FiremodeSettings |
| struct | chrReservations_t |
| How many TUs (and of what type) did a player reserve for a unit? More... | |
| struct | ugv_t |
| Defines a type of UGV/Robot. More... | |
| class | BodyPartData |
| class | BodyData |
| struct | teamNames_t |
| struct | teamDef_t |
| struct | teamDef_t::model_t |
| struct | woundInfo_t |
| Info on a wound. More... | |
| struct | implant_t |
| struct | character_t |
| Describes a character with all its attributes. More... | |
Macros | |
| #define | ABILITY_NUM_TYPES SKILL_CLOSE |
| #define | MAX_UGV 8 |
| #define | MAX_TEAMDEFS 64 |
| #define | MAX_CHARACTER_TEMPLATES 24 |
| #define | MAX_TEMPLATES_PER_TEAM 16 |
| #define | BODYPART_MAXTYPE 4 |
| #define | MAX_CHARACTER_IMPLANTS 4 |
Enumerations | |
| enum | killtypes_t { KILLED_ENEMIES , KILLED_CIVILIANS , KILLED_TEAM , KILLED_NUM_TYPES } |
| enum | abilityskills_t { ABILITY_POWER , ABILITY_SPEED , ABILITY_ACCURACY , ABILITY_MIND , SKILL_CLOSE , SKILL_HEAVY , SKILL_ASSAULT , SKILL_SNIPER , SKILL_EXPLOSIVE , SKILL_PILOTING , SKILL_TARGETING , SKILL_EVADING , SKILL_NUM_TYPES } |
| enum | reservation_types_t { RES_REACTION , RES_CROUCH , RES_SHOT , RES_ALL , RES_ALL_ACTIVE , RES_TYPES } |
| enum | actorSound_t { SND_DEATH , SND_HURT , SND_MAX } |
| Types of actor sounds being issued by CL_ActorPlaySound(). More... | |
| enum | nametypes_t { NAME_NEUTRAL , NAME_FEMALE , NAME_MALE , NAME_LAST , NAME_FEMALE_LAST , NAME_MALE_LAST , NAME_NUM_TYPES } |
| enum | modifier_types_t { MODIFIER_ACCURACY , MODIFIER_SHOOTING , MODIFIER_MOVEMENT , MODIFIER_SIGHT , MODIFIER_REACTION , MODIFIER_TU , MODIFIER_MAX } |
Functions | |
| const chrTemplate_t * | CHRSH_GetTemplateByID (const teamDef_t *teamDef, const char *templateId) |
| void | CHRSH_CharGenAbilitySkills (character_t *chr, bool multiplayer, const char *templateId="") __attribute__((nonnull)) |
| Generates a skill and ability set for any character. | |
| const char * | CHRSH_CharGetBody (const character_t *const chr) __attribute__((nonnull)) |
| Returns the body model for the soldiers for armoured and non armoured soldiers. | |
| const char * | CHRSH_CharGetHead (const character_t *const chr) __attribute__((nonnull)) |
| Returns the head model for the soldiers for armoured and non armoured soldiers. | |
| bool | CHRSH_IsTeamDefAlien (const teamDef_t *const td) __attribute__((nonnull)) |
| Check if a team definition is alien. | |
| bool | CHRSH_IsTeamDefRobot (const teamDef_t *const td) __attribute__((nonnull)) |
| Check if a team definition is a robot. | |
| bool | CHRSH_IsArmourUseableForTeam (const objDef_t *od, const teamDef_t *teamDef) |
| const implant_t * | CHRSH_ApplyImplant (character_t &chr, const implantDef_t &implant) |
| Add a new implant to a character. | |
| void | CHRSH_UpdateImplants (character_t &chr) |
| Updates the characters permanent implants. Called every day. | |
| #define ABILITY_NUM_TYPES SKILL_CLOSE |
Definition at line 54 of file chr_shared.h.
Referenced by AM_UpdateSurivorsAfterBattle(), CL_SwapSkills(), Com_ParseFire(), and G_GetEarnedExperience().
| #define BODYPART_MAXTYPE 4 |
Definition at line 266 of file chr_shared.h.
Referenced by AI_SetStats(), CHAR_ParseData(), Com_ParseBodyPart(), and G_SendCharacterData().
| #define MAX_CHARACTER_IMPLANTS 4 |
Definition at line 371 of file chr_shared.h.
| #define MAX_CHARACTER_TEMPLATES 24 |
Definition at line 229 of file chr_shared.h.
Referenced by Com_ParseCharacterTemplate().
| #define MAX_TEAMDEFS 64 |
Definition at line 228 of file chr_shared.h.
Referenced by Com_ParseTeam(), and G_ClientReadCharacter().
| #define MAX_TEMPLATES_PER_TEAM 16 |
Definition at line 230 of file chr_shared.h.
| #define MAX_UGV 8 |
Definition at line 227 of file chr_shared.h.
Referenced by Com_ParseUGVs().
| enum abilityskills_t |
| Enumerator | |
|---|---|
| ABILITY_POWER | |
| ABILITY_SPEED | |
| ABILITY_ACCURACY | |
| ABILITY_MIND | |
| SKILL_CLOSE | |
| SKILL_HEAVY | |
| SKILL_ASSAULT | |
| SKILL_SNIPER | |
| SKILL_EXPLOSIVE | |
| SKILL_PILOTING | |
| SKILL_TARGETING | |
| SKILL_EVADING | |
| SKILL_NUM_TYPES | |
Definition at line 36 of file chr_shared.h.
| enum actorSound_t |
Types of actor sounds being issued by CL_ActorPlaySound().
| Enumerator | |
|---|---|
| SND_DEATH | Sound being played on actor death. |
| SND_HURT | Sound being played when an actor is being hit. |
| SND_MAX | |
Definition at line 218 of file chr_shared.h.
| enum killtypes_t |
| Enumerator | |
|---|---|
| KILLED_ENEMIES | Killed enemies |
| KILLED_CIVILIANS | Civilians, animals |
| KILLED_TEAM | Friendly fire, own team, partner-teams. |
| KILLED_NUM_TYPES | |
Definition at line 27 of file chr_shared.h.
| enum modifier_types_t |
Definition at line 255 of file chr_shared.h.
| enum nametypes_t |
| Enumerator | |
|---|---|
| NAME_NEUTRAL | |
| NAME_FEMALE | |
| NAME_MALE | |
| NAME_LAST | |
| NAME_FEMALE_LAST | |
| NAME_MALE_LAST | |
| NAME_NUM_TYPES | |
Definition at line 232 of file chr_shared.h.
| enum reservation_types_t |
| Enumerator | |
|---|---|
| RES_REACTION | |
| RES_CROUCH | |
| RES_SHOT | |
| RES_ALL | |
| RES_ALL_ACTIVE | |
| RES_TYPES | Max. |
Definition at line 208 of file chr_shared.h.
| const implant_t * CHRSH_ApplyImplant | ( | character_t & | chr, |
| const implantDef_t & | implant ) |
Add a new implant to a character.
Definition at line 180 of file chr_shared.cpp.
References Com_Printf(), implant_t::def, i, objDef_t::id, objDef_t::implant, character_t::implants, implantDef_t::installationTime, implant_t::installedTime, itemEffect_t::isPermanent, implantDef_t::item, lengthof, itemEffect_t::period, objDef_t::strengthenEffect, and implant_t::trigger.
Referenced by RunImplant().
| void CHRSH_CharGenAbilitySkills | ( | character_t * | chr, |
| bool | multiplayer, | ||
| const char * | templateId ) |
Generates a skill and ability set for any character.
| [in] | chr | Pointer to the character, for which we generate stats. |
| [in] | multiplayer | If this is true we use the skill values from soldier_mp |
| [in] | templateId | Specifies the template to be used for non-MP |
Definition at line 221 of file chr_shared.cpp.
References ABILITY_MIND, teamDef_t::characterTemplates, CHRSH_GetTemplateByID(), chrScoreGlobal_t::experience, frand(), GET_MORALE, character_t::HP, i, chrTemplate_t::id, teamDef_t::id, chrScoreGlobal_t::initialSkills, int(), MAX_SKILL, character_t::maxHP, character_t::morale, teamDef_t::numTemplates, Q_strnull(), chrTemplate_t::rate, character_t::score, SKILL_NUM_TYPES, chrScoreGlobal_t::skills, chrTemplate_t::skills, Sys_Error(), teamDef_t::team, TEAM_PHALANX, and character_t::teamDef.
Referenced by AI_SetStats(), and CL_GenerateCharacter().
| const char * CHRSH_CharGetBody | ( | const character_t *const | chr | ) |
Returns the body model for the soldiers for armoured and non armoured soldiers.
| [in] | chr | Pointer to character struct |
Definition at line 297 of file chr_shared.cpp.
References objDef_t::armourPath, character_t::body, CHRSH_IsTeamDefRobot(), Com_sprintf(), Item::def(), Inventory::getArmour(), character_t::inv, objDef_t::isArmour(), MAX_VAR, character_t::path, Sys_Error(), and character_t::teamDef.
Referenced by AI_InitPlayer(), CL_CharacterSkillAndScoreCvars(), CP_UpdateActorAircraftVar(), G_ClientAssignDefaultActorValues(), and GAME_LoadCharacter().
| const char * CHRSH_CharGetHead | ( | const character_t *const | chr | ) |
Returns the head model for the soldiers for armoured and non armoured soldiers.
| [in] | chr | Pointer to character struct |
Definition at line 319 of file chr_shared.cpp.
References objDef_t::armourPath, Com_sprintf(), Item::def(), Inventory::getArmour(), character_t::head, character_t::inv, objDef_t::isArmour(), MAX_VAR, character_t::path, teamDef_t::robot, Sys_Error(), and character_t::teamDef.
Referenced by AI_InitPlayer(), CL_CharacterSkillAndScoreCvars(), CP_UpdateActorAircraftVar(), G_ClientAssignDefaultActorValues(), and GAME_LoadCharacter().
| const chrTemplate_t * CHRSH_GetTemplateByID | ( | const teamDef_t * | teamDef, |
| const char * | templateId ) |
Definition at line 108 of file chr_shared.cpp.
References teamDef_t::characterTemplates, i, chrTemplate_t::id, teamDef_t::numTemplates, Q_streq, and Q_strnull().
Referenced by CHRSH_CharGenAbilitySkills(), and CP_ParseAlienTeam().
Definition at line 88 of file chr_shared.cpp.
References teamDef_t::armour, objDef_t::isArmour(), teamDef_t::team, and objDef_t::useable.
Referenced by GAME_ItemIsUseable(), and TEST_F().
| bool CHRSH_IsTeamDefAlien | ( | const teamDef_t *const | td | ) |
Check if a team definition is alien.
| [in] | td | Pointer to the team definition to check. |
Definition at line 83 of file chr_shared.cpp.
References teamDef_t::team, and TEAM_ALIEN.
Referenced by AI_SetStats(), CP_ParseCampaignData(), G_TreatActor(), GAME_CP_TeamIsKnown(), GAME_SK_SetMissionParameters(), and AlienContainment::isLifeSupported().
| bool CHRSH_IsTeamDefRobot | ( | const teamDef_t *const | td | ) |
Check if a team definition is a robot.
| [in] | td | Pointer to the team definition to check. |
Definition at line 103 of file chr_shared.cpp.
References teamDef_t::robot.
Referenced by AI_FindBestFiredef(), AI_SetStats(), CHRSH_CharGetBody(), G_ActorSetMaxs(), G_BleedWounds(), G_Damage(), G_MoraleBehaviour(), HOS_EntryWoundData(), HUD_ActorWoundData_f(), and AlienContainment::isLifeSupported().
| void CHRSH_UpdateImplants | ( | character_t & | chr | ) |
Updates the characters permanent implants. Called every day.
Definition at line 140 of file chr_shared.cpp.
References CHRSH_UpdateCharacterWithEffect(), implant_t::def, i, character_t::implants, implant_t::installedTime, itemEffect_t::isPermanent, implantDef_t::item, lengthof, itemEffect_t::period, implant_t::removedTime, objDef_t::strengthenEffect, and implant_t::trigger.
Referenced by HOS_HospitalRun(), and RunImplant().