using Unity.Entities; namespace ProjectM.Simulation { /// /// One pending hit against a damageable entity, queued as a per-entity buffer element. The server /// appends a DamageEvent when a projectile hits (ProjectileDamageSystem), then HealthApplyDamageSystem /// drains the buffer once per tick to subtract from Health. Buffering decouples hit detection from /// health resolution and lets multiple simultaneous hits accumulate before being applied. Not /// replicated — only Health.Current is a GhostField; the buffer is server-side and cleared each tick. /// public struct DamageEvent : IBufferElementData { /// Damage to subtract from the target's Health.Current (world health units). public float Amount; /// NetworkId of the firing player that caused this hit (attribution / self-hit filtering upstream). public int SourceNetworkId; } }