CBaseCombatCharacter
Jump to navigation
Jump to search
Code classes:
CBaseCombatCharacter
is a code class that holds functionality common between NPCs, players, and a number of miscellaneous objects.
ConVars/Commands[edit | edit source]
ConVar/Command | Parameters or default value | Parameter Type | Effect |
---|---|---|---|
ai_show_hull_attacks | 0 | 0 disables, 1 enables | Shows the range of some melee-based attacks. |
ai_force_serverside_ragdoll | 0 | 0 disables, 1 enables | To do: Effect description. |
ai_use_visibility_cache | 1 | 0 disables, 1 enables | To do: Effect description. |
phys_stressbodyweights | 5 | To do: Effect description. | |
phys_impactforcescale | 1 | To do: Effect description. | |
phys_upimpactforcescale | 0.375 | To do: Effect description. |
Keyvalues[edit | edit source]
- Relationship (Not in FGD)
(Relationship)
<string>
- Sets a relationship for this entity, without requiring an
ai_relationship
entity to be set up. - Format:
target_name_or_class disposition priority
- Physics Impact Damage Scale
(physdamagescale)
<float>
- Multiplier for damage amount when this entity is hit by a physics object. With a value of 0 the entity will take no damage from physics.
- Hull Type (Not in FGD)
(HullType)
<choices>
(available in all games since ) - Bounding box setting for this entity. To do: Does this work? No effects observed.
- 0: Human
- 1: Small centered
- 2: Wide human
- 3: Tiny
- 4: Wide short
- 5: Medium
- 6: Tiny centered
- 7: Large
- 8: Large centered
- 9: Medium tall
- 10: Tiny fluid
- 11: Medium big
- Blood Color (Not in FGD)
(BloodColor)
<choices>
(available in all games since ) - Color of blood when this entity is hurt. There are other valid values, but they have no apparent effect. Effects have only been seen in Portal 2, with
player
andnpc_personality_core
.- -1: No blood
- 0: Red blood
Inputs[edit | edit source]
- KilledNPC (Not in FGD)
- Tells the entity it killed something. Despite the name, this can include a player. This input is automatically sent by the victim when they die. Responses to this input vary by entity (
OnKilledNPC
function). - PhysDamageScale
<float>
- Sets Physics Impact Damage Scale.