Health: Difference between revisions

From Valve Developer Community
Jump to navigation Jump to search
m (added language bar. also some formatting.)
No edit summary
 
(17 intermediate revisions by 5 users not shown)
Line 1: Line 1:
{{lang|Health}}
{{LanguageBar}}
{{Abstract Mapping}}
{{Abstract Mapping}}
<br>
__NOTOC__
__NOTOC__
 
'''Health''', or '''Health Points''' ("HP", occasionally "Hit Points"), represents a character's physical status in a video game. Most [[Source]] engine games use a traditional health points system, where a character is spawned with a certain number of health points which are displayed in the [[HUD]]. Taking damage will subtract from the character's health, and the character will die when HP reaches 0. Most games offer powerups and items to restore health.
'''Health''', or '''Health Points''' (HP), represents a character's physical status in a video game. Most [[Source]] engine games use a traditional health points system, where a character is spawned with a certain number of health points which are displayed in the [[HUD]]. Taking damage will subtract from the character's health, and the character will die when HP reaches 0. Most games offer powerups and items to restore health.
{{note|Player's or NPCs' health is not updated instantly when it's modified via <code>addoutput "health [number]"</code>. Health will update only when player or NPC receives damage or gains health. If player's or NPC's health is set to 0 or lower they will still be alive but will die in one hit from any damage source.<br>
{{Bug|Sometimes when a player is in godmode in the Source engine, the player may reach 0 health but still be alive.}}
Most NPC and player entities have a <kbd>SetHealth</kbd> input available to change their health properly, which also respects their <kbd>max_health</kbd> keyvalue.}}
Some games, such as {{Portal|2}}, use an alternative "regenerating health" scheme, where the player's health quickly regenerates when the player is not taking damage. The health may also not be displayed onscreen.
Some games, such as {{Portal|2}}, use an alternative "regenerating health" scheme, where the player's health quickly regenerates when the player is not taking damage. The health may also not be displayed onscreen.


Line 20: Line 21:
* [[VGUI Image Progress Bar]]
* [[VGUI Image Progress Bar]]


==Health Entities==
== {{src}} Source Health Entities==
=== {{hl2|4}}, {{hl2ep1|4}}, {{hl2ep2|4}} ===
=== {{hl2series|4}} ===
* {{ent|func_recharge}}
* {{ent|func_recharge}}
* {{ent|func_healthcharger}}
* {{ent|func_healthcharger}}
Line 31: Line 32:
* {{ent|item_suitcharger}}
* {{ent|item_suitcharger}}
* {{ent|npc_antlion_grub}}
* {{ent|npc_antlion_grub}}
=== {{hls|4}} & {{hldms|4}} ===
* <code>[[func healthcharger (Half-Life: Source)|func_healthcharger]]</code>
* <code>[[func recharge (Half-Life: Source)|func_recharge]]</code>
* <code>[[item battery (Half-Life: Source)|item_battery]]</code>
* <code>[[item healthkit (Half-Life: Source)|item_healthkit]]</code>


=== {{tf2|4}} ===
=== {{tf2|4}} ===
Line 39: Line 46:
* {{ent|obj_dispenser}}
* {{ent|obj_dispenser}}


=== {{l4d|4}} & {{l4d2|4}} ===
=== {{l4dseries|4}} ===
* {{ent|prop_health_cabinet}}
* {{ent|prop_health_cabinet}}
* {{ent|weapon_first_aid_kit_spawn}}
* {{ent|weapon_first_aid_kit_spawn}}
Line 52: Line 59:
* {{ent|asw_pickup_medkit}}
* {{ent|asw_pickup_medkit}}


=== {{sin|4}} ===
=== {{sineps|4}} ===
* {{ent|item_antigen_dispenser}}
* {{ent|item_antigen_dispenser}}
* {{ent|item_healthvial}}
* {{ent|item_healthvial}}
Line 99: Line 106:
* {{ent|item_p_occult_regen}}
* {{ent|item_p_occult_regen}}


== {{goldsrc}} GoldSrc health entities ==
=== {{hl|4}}, {{hlop4|4}}, {{hlbs|4}} ===
=== {{hl|4}}, {{hlop4|4}}, {{hlbs|4}} ===
* <code>[[func healthcharger (GoldSource Engine)|func_healthcharger]]</code>{{gldsrc}}
* {{ent|func_healthcharger|engine=goldsrc}}
* <code>[[func recharge (GoldSource Engine)|func_recharge]]</code>{{gldsrc}}
* {{ent|func_recharge|engine=goldsrc}}
* <code>[[item battery (GoldSource Engine)|item_battery]]</code>{{gldsrc}}
* {{ent|item_battery|engine=goldsrc}}
* <code>[[item healthkit (GoldSource Engine)|item_healthkit]]</code>{{gldsrc}}
* {{ent|item_healthkit|engine=goldsrc}}
* {{ent|func_door|engine=goldsrc}}/{{ent|func_door_rotating|engine=goldsrc}} ({{mono|healthvalue}} KV)


=== {{tfc|4}} ===
=== {{tfc|4}} ===
* <code>[[func healthcharger (GoldSource Engine)|func_healthcharger]]</code>{{gldsrc}}
* {{ent|func_healthcharger|engine=goldsrc}}
* <code>[[item healthkit (GoldSource Engine)|item_healthkit]]</code>{{gldsrc}}
* {{ent|item_healthkit|engine=goldsrc}}


[[Category:Hubs]]
[[Category:Hubs]]
[[Category:Abstract Mapping]]
[[Category:Abstract Mapping]]

Latest revision as of 07:29, 22 June 2025

English (en)中文 (zh)Translate (Translate)
Abstract Mapping series Discuss your thoughts - Help us develop the articles or ideas you want

Ammunition | List of HL2 Animals and Creatures | Mapping with Antlions | Beams and Lasers | Cables and Ropes | Moving Clouds | Color Theory in Level Design | Combat | Combine | Compression (Source 1) | Doors | Dust, Fog, & Smoke | Elevators | Level Transitions | Environmental Lighting, Sun, Weather, & Outdoors | Explosions | Fire | Half-Life 2 Foliage | Glass & Windows | Headcrab | Health | Ladders | Lighting | Optimization (level design) | Physics | Retinal scanners | Sound and Music | Special effects | Terrain | Trains | Turrets | Water | Weapons | Zombie


Health, or Health Points ("HP", occasionally "Hit Points"), represents a character's physical status in a video game. Most Source engine games use a traditional health points system, where a character is spawned with a certain number of health points which are displayed in the HUD. Taking damage will subtract from the character's health, and the character will die when HP reaches 0. Most games offer powerups and items to restore health.

Note.pngNote:Player's or NPCs' health is not updated instantly when it's modified via addoutput "health [number]". Health will update only when player or NPC receives damage or gains health. If player's or NPC's health is set to 0 or lower they will still be alive but will die in one hit from any damage source.
Most NPC and player entities have a SetHealth input available to change their health properly, which also respects their max_health keyvalue.

Some games, such as Portal Portal, use an alternative "regenerating health" scheme, where the player's health quickly regenerates when the player is not taking damage. The health may also not be displayed onscreen.

While in many multiplayer games all characters start with the same amount of health, class-based games such as Team Fortress 2 Team Fortress 2 sometimes assign different starting health values to different classes.

Following is a list of health-related articles:

Health Level Design

Health Coding

Source Source Health Entities

Half-Life 2 series Half-Life 2 series

Half-Life: Source Half-Life: Source & Half-Life Deathmatch: Source Half-Life Deathmatch: Source

Team Fortress 2 Team Fortress 2

Left 4 Dead seriesLeft 4 Dead series Left 4 Dead series

Counter-Strike: Global Offensive Counter-Strike: Global Offensive

Alien Swarm Alien Swarm

SiN Episodes SiN Episodes

The Ship: Murder Party The Ship: Murder Party

Dark Messiah of Might and Magic Dark Messiah of Might and Magic

Vampire: The Masquerade – Bloodlines Vampire: The Masquerade – Bloodlines

GoldSrc GoldSrc health entities

Half-Life Half-Life, Half-Life: Opposing Force Half-Life: Opposing Force, Half-Life: Blue Shift Half-Life: Blue Shift

Team Fortress Classic Team Fortress Classic