Mac DAMAGE_ApplyDamageToUnit: void __cdecl (pGame, pUnit, pVictim, bApplyDefenseReduction, pDamage)
The Mac body reads five stack args, [EBP+8]..[EBP+0x18], none above that (checked by disassembly search), and ends in a plain RET. [EBP+0xc] is the attacker (passed as ECX to DAMAGE_ApplyCold at 0x0027dc07), [EBP+0x14] is a flag tested against 0, and [EBP+0x18] is the damage struct (+0x30 cold length read at 0x0027dbfe). The caller SKILLNEC_ApplyBloodCost 0x00262658 stores [ESP]=pGame, [ESP+4]=pUnit, [ESP+8]=pUnit, [ESP+0xc]=0, [ESP+0x10]=&D2DamageStrc and ignores EAX. Same roles and order as the Windows twin 0x0057c6c0.
Changes 1, applied together
Set prototype
mac 0x0027d0d5signatureundefined DAMAGE_ApplyDamageToUnit(void)→void DAMAGE_ApplyDamageToUnit(D2GameStrc* pGame, D2UnitStrc* pUnit, D2UnitStrc* pVictim, int32_t bApplyDefenseReduction, D2DamageStrc* pDamage)conventionunknown→__cdecl