Mac SKILLDESC_CalcStatGroupValue: __fastcc int32_t (pUnit, eStat, nStatValue, pItemStatCostTxt)
Ghidra vmac 111 · 3c6740e
Mac body: ECX is saved and later tested as a unit (type == 4, then item-type check 0x39); EDX is saved and compared with stat 0x7a; [EBP+8] (EBX) is the stat value that is scaled and shifted; [EBP+0xc] (EDI) is the ItemStatCost row (+0x54 desc func, +0x55/+0x18 shifts, +0x56 linked stat index into a 0x144-stride table); the computed value is returned in EAX; single RET. Windows twin SKILLDESC_CalcStatGroupValue 0x004e4c50 is int32_t (D2UnitStrc * pUnit, eD2UnitStat eStat, int32_t nStatValue, D2ItemStatCostTxt * pItemStatCostTxt); same order on Mac (ECX, EDX, stack, stack).
Changes 1, applied together
Set prototype
mac 0x000c519bsignatureundefined SKILLDESC_CalcStatGroupValue(void)→int32_t SKILLDESC_CalcStatGroupValue(D2UnitStrc * pUnit, eD2UnitStat eStat, int32_t nStatValue, D2ItemStatCostTxt * pItemStatCostTxt)conventionunknown→__fastcc