Skip to content

Head Trauma Feature #326

@0xE69

Description

@0xE69

Head Trauma Feature

Player Impact: Projectile headshots trigger temporary “brain trauma” effects. Severity derives from projectile impact energy after helmet mitigation—ranging from a momentary screen flash to severe nausea, slowness, and aim sway.

Energy Model: Each projectile exposes impactEnergy (damage × speed or KE). Headshots are detected via existing hitbox logic; without helmets, full energy applies. Helmets define absorption, stoppingPower, durabilityPerEnergy, and optional stunThreshold. Absorbed energy reduces helmet durability; the remainder feeds severity selection. Exceeding stopping capacity can still stun and degrade the helmet.

Effect Tiers:

Minor (<20): 10–20 ticks of brief blindness/flicker.
Moderate (20–60): ~5 s nausea/disorientation plus light slowness or dampened turn rate.
Severe (≥60): ~8 s confusion + stronger slowness, sprint suppression, and short aim sway. No-helmet multiplier (e.g., 1.4×) pushes more hits into higher tiers.
Configuration: Forge/JSON config exposes toggles and thresholds (enabled, tier limits, multipliers, sway duration). Helmet entries override absorption/stopping/durability factors for tuning without recompiling.

Implementation Notes:

Apply standard armor damage reduction first, then process trauma using remaining energy.
Client effects: potion statuses for nausea/blindness; custom packets for aim/turn modifiers.
Generate missing helmet assets/entries with sensible defaults; log stun-through events for balancing.
Provide server toggles to disable severe penalties for competitive play and guard client-sent stun state.

Metadata

Metadata

Assignees

No one assigned

    Labels

    ImprovementNew feature or request

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions