# Periodic aura hits (`src/mods/aurahits.cpp`) Rebalancing request (user, 2026-10-15): "Blicke wie Klingen" (art 0x3f8, `GUI_MOVE_KLINGENBLICK`) hit only one enemy per tick; it should hit all enemies in range. ## What the game does (measured with a hit log, 2026-10-15) The aura gives the hero an effect of kind 0x12 (value 0x445f in the test). Its hits reach the enemies as `cEvent_creature` 5 (attacker id at +8, the damage at +0x18.. in one of four damage-type slots, chosen at random), sent from `0x56323d`, one enemy about once per second. Code (creature arts update, branch `0x562f08`, only for effects of kind 0x12 of the local player's creature): - timer at effect +8 (a vector holding one int, ms); every 1000 ms: - walk the creatures near the player (`0xad1c60`, 8 bytes each, count `0xad1b48`); a creature within `(cCreatureArts +0x56 + 20) * 10` of the owner (`cCreature::DistanceTo` `0x536f20`) becomes the target if there is none yet, otherwise replaces it with 1/3 chance; - player heroes as targets go through PvP checks (`0x4d4be0`); - the hit: `cEvent_creature` 5 built on the stack, sent with the target's `ReceiveOrder` (vf18). ## The mod `mov eax, [ecx]; call [eax+18h]` at `0x56323b` becomes a call of `HitAllInRange` (via a thunk passing ebp = cCreatureArts and ebx = the effect's offset): the chosen enemy gets its hit, then every other living creature of the nearby list within the same range gets a copy of the same hit. Player heroes are skipped (they need the PvP checks). Applies to every effect of kind 0x12, i.e. by behaviour, not by art id. ## Damage type and life leech (2026-10-15) - The game puts the aura's value into one of the four damage slots at random (physical, fire, magic, poison), so a quarter of the ticks poisoned; the mod makes every aura hit physical (user's choice). - Life leech, its beam and sound are applied by the damage code (`0x56aff0`, leech block `0x5707a4`..`0x570a88`: property 0x349 x difficulty factor x damage x distance falloff, capped at max health) for the hit's attacker, order +0x1c. Weapon hits carry the hero's id there, enemy hits the enemy's, aura hits 0, so they never leeched. The mod sets it to the aura's owner.