Guide
Game health and damage systems explained
Every combat encounter, platform hazard, and environmental trap eventually asks the same question: how much can this entity survive, and what happens when it cannot? Health and damage systems are the backbone of tension in action games, the spreadsheet heart of RPGs, and the fairness contract in competitive multiplayer. A good system is readable (players understand why they died), tunable (designers can rebalance without rewriting code), and extensible (shields, armor, resistances, and status effects plug in cleanly). A bad one produces opaque one-shots, healing that never matters, or damage numbers that mean nothing. This guide covers resource pools, damage pipelines, formula design, healing and death hooks, UI feedback, multiplayer authority, genre patterns, and a production checklist — with links to combat systems and difficulty tuning for the surrounding context.
Resource pools: HP, shields, armor, and stamina
Most games expose at least one health pool — a numeric value that decreases when damage is applied and triggers death or knockdown at zero. But layering additional pools creates tactical depth:
- Hit points (HP) — the primary survivability meter. Simple, universal, easy to display. Works for players, enemies, and destructible objects alike.
- Shields / energy barriers — a secondary pool that regenerates quickly (Halo shields, Destiny overshields). Shields absorb damage first, encouraging brief disengagement without full healing.
- Armor / damage reduction — not always a separate pool. Can be a flat subtraction, a percentage reduction, or an ablative layer (breaks after N hits). Armor encourages weapon switching and target prioritization.
- Stamina / poise — governs whether an entity can act while being hit. Stamina depletion causes stagger; poise breaks enable combos. Often separate from HP but tightly coupled in feel.
Decide early whether pools are independent or ordered. Ordered absorption (shield then armor then HP) is easy to communicate in UI. Independent pools (shield and HP both visible, damage splits) require clearer telegraphing. For enemies, consider hiding inner pools until the outer layer breaks — a classic reveal moment that teaches player progression mid-fight.
Damage types, tags, and resistances
Flat numeric damage works for arcade games; most RPGs and looter-shooters add damage types that interact with resistances, vulnerabilities, and immunities:
- Physical vs elemental — slash/pierce/blunt or fire/ice/lightning/poison. Elemental types enable buildcraft and enemy variety without new animations.
- True / pure damage — bypasses armor and resistances. Use sparingly; it is the escape hatch when other systems become too complex.
- Environmental and fall damage — often a separate pipeline with its own caps and immunity windows (i-frames after respawn).
- DoT (damage over time) — ticks on an interval, usually managed by the status-effect system. Stack rules (refresh vs stack vs replace) belong in data, not hard-coded per poison type.
Store resistances as multipliers on a lookup table
keyed by (damage_type, target_tag). A “Fire Elemental” enemy
might have fire: 0.0 (immune), ice: 1.5
(weak), and physical: 1.0 (normal). Expose these values in
tooling so designers can tune without programmer intervention.
Damage formulas: additive, multiplicative, and clamping
The damage pipeline typically runs: base damage, modifiers, mitigation, final clamp, apply to pool. How modifiers combine determines whether buildcraft stays interesting or breaks into one-shot metas.
Common pipeline stages
- Base damage — weapon stat, ability coefficient, or environmental constant.
- Attacker modifiers — crit multiplier, buffs, combo scaling, elevation bonus.
- Defender mitigation — armor formula, block/parry reduction, invulnerability frames.
- Floor and ceiling — minimum 1 damage (so progress always happens), maximum percent-of-max-HP cap (prevent one-shots).
Additive bonuses (+20% damage, +15% damage) sum before multiplication — predictable, easy to reason about. Multiplicative bonuses (1.2x then 1.15x) explode quickly; cap them or use diminishing returns for stacked buffs. Many RPGs use a hybrid: additive within categories (all “increased damage” stats add), multiplicative across categories (increased vs more vs crit).
Armor formulas deserve explicit design. Linear subtraction
(damage - armor, floored at 0) is simple but breaks at high
armor values. Percentage reduction
(damage * (1 - armor / (armor + K))) asymptotes smoothly —
the constant K controls how quickly armor stops mattering. Document the
formula in your design wiki; players will datamine it anyway.
Healing, regeneration, and sustain
Damage only creates tension if recovery is possible but costly. Healing systems fall into a few archetypes:
- Passive regeneration — out-of-combat only (cover shooters), or always-on with a low rate (MOBAs). Pair with a “combat tag” timer that pauses regen during fights.
- Active healing items — potions, medkits, estus flasks. Limited charges create resource management. Animation wind-up prevents healing mid-combo in PvP.
- Lifesteal / on-kill heal — rewards aggression. Cap per second to prevent snowballing in multiplayer.
- Healing over time (HoT) — ticks like DoT; can be interrupted by damage (WoW-style) or uninterruptible (casual mobile).
Match heal throughput to your difficulty curve. If average enemy DPS is 20 HP/s and a medkit heals 40 HP over 2 seconds, players need roughly 2 seconds of safety to recover one enemy's worth of health — a concrete tuning knob. Track time-to-kill (TTK) and time-to-full-heal as paired metrics during playtests.
Death, knockdown, and downstream hooks
Reaching zero HP is rarely the end of the logic chain. Define explicit death states and what systems listen for them:
- Instant death — arcade, roguelike permadeath runs. Trigger game-over, run summary, meta-progression unlock checks.
- Knockdown / down-but-not-out — teammates revive within a timer (co-op shooters). Separate “incapacitated” pool from dead to allow clutch saves.
- Death with respawn — checkpoint respawn, soul retrieval (Dark Souls), or wave-based retry. Hook into save systems and enemy reset rules.
- Non-lethal defeat — HP floor at 1 for story beats; triggers scripted capture or mercy option.
Emit a single DamageApplied event and a distinct EntityDied event. Quest systems, achievements, loot tables, AI squad morale, and audio stingers should subscribe — never scatter death checks across 40 scripts. Include killer ID, damage type, overkill amount, and whether the kill was a crit for analytics and kill-feed UI.
UI feedback and game feel
Players learn your damage model through feedback loops, not tooltips. Strong health/damage UX includes:
- Health bar behavior — delayed damage chunk (shows recent hit), smooth drain vs instant step, color shifts at low HP. See HUD design for layout patterns.
- Damage numbers — floating combat text with color by type (crit = gold, heal = green, blocked = gray). Pool and batch numbers to avoid spam in horde modes.
- Hit reactions — flash shader, brief hit-stop, camera shake scaled to damage percent. Invulnerability frames after hit (i-frames) prevent unfair chain deaths — typically 0.3–1.0 seconds in action games.
- Audio cues — distinct sounds for shield break, armor crack, near-death heartbeat. Audio sells impact when numbers are hidden (hardcore modes).
Accessibility options: damage number toggle, high-contrast health bars, reduced screen shake, and optional “why did I die?” recap showing last three damage sources.
Multiplayer authority and cheating
In networked games, the server (or host) must own HP values. Clients may predict damage locally for responsiveness, but authoritative reconciliation prevents god-mode hacks. Patterns:
- Server-validated hits — client sends input + aim vector; server raycasts, computes damage, broadcasts result. Never trust client “I hit for 500.”
- Snapshot interpolation — display HP between server ticks; snap on large discrepancies.
- Lag compensation — rewind hitbox positions to client's view time for fairness; document tradeoffs for high-ping players.
- Anti-cheat hooks — log impossible heal rates, negative HP, damage exceeding weapon caps. Pair with broader integrity patterns in competitive titles.
For PvE co-op, relaxed authority is acceptable; for PvP, treat every damage and heal as a signed, sequenced server event.
Genre decision table
| Genre | Typical pool model | Formula complexity | Healing style |
|---|---|---|---|
| Arcade action | Single HP, no armor | Flat damage, simple crit | Health pickups on map |
| Soulslike | HP + stamina + poise | Moderate armor %, i-frames core | Limited flask charges at bonfire |
| Looter shooter | HP + shield + armor rating | High — types, resist, proc effects | Cover regen + medkit cooldown |
| Turn-based RPG | HP + MP, elemental matrix | Full stat sheet, predictable | Spells, items, post-combat rest |
| Roguelike | Small HP pool, spikes deadly | Low — readability over depth | Floor drops, shop, risk/reward rooms |
| Fighting game | HP bar, no mid-round heal | Per-move fixed damage + scaling | None (round reset) |
Production checklist
- Define a damage event schema — source, target, base, type, crit flag, final amount, overkill, timestamp. Log every instance in debug builds.
- Centralize the damage pipeline — one function or system
applies all damage; no direct
hp -= xscattered in gameplay code. - Data-drive types and resistances — designers tune in spreadsheets; code reads lookup tables at runtime.
- Document modifier stacking rules — additive vs multiplicative, order of operations, caps. Put examples in the wiki.
- Pair TTK with heal throughput — playtest with target skill levels; graph deaths per minute vs healing used.
- Implement i-frames and damage immunity tags — cutscenes, respawn, roll-dodge, and spawn protection share one system.
- Build death hooks early — quests, loot, AI, audio, and analytics subscribe to EntityDied from day one.
- Server-authoritative in multiplayer — validate hits and HP on the host; reconcile client prediction gracefully.
- Accessibility pass on HUD — colorblind-safe health states, configurable damage numbers, reduced camera shake option.
Key takeaways
- Health systems are contracts with the player — damage must feel fair and readable; opaque formulas erode trust faster than hard difficulty.
- Layer pools deliberately — shields, armor, and poise add depth only when absorption order and UI communicate them clearly.
- One damage pipeline, many callers — combat, environment, DoT, and fall damage share the same apply function and event bus.
- Healing and damage are paired metrics — tune TTK and sustain together on your difficulty curve, not in isolation.
- Death is an integration point — emit clean events so quests, loot, AI, and analytics do not reimplement death detection.
Related reading
- Game combat systems explained — hitboxes, frame data, and the combat loop that feeds damage
- Game status effects explained — DoT, HoT, buffs, and crowd control on top of HP
- Game difficulty curves explained — pacing challenge against player survivability
- Game UI and HUD design explained — health bars, damage feedback, and readability