REDIVIVUS

Proposals / #1267

Mac SUNITINACTIVE_CheckDeadMonsterAtCoords: BOOL __cdecl (pGame, pRoom, nPosX, nPosY, nClassId)

checked · by KierTaylor · submitted 2026-11-06

The Mac body halts on a NULL [EBP+8] (pGame, line 0x6da) and a NULL [EBP+0xc] (pRoom, line 0x6db), and checks [EBP+0x10]/[EBP+0x14] (the coordinates) for zero, as the Windows twin 0x005429b0 does (pGame, pRoom, nPosX, nPosY, nClassId). The only caller, AI_Monster_FindDeadMonsterNearby 0x002ae570, stores five slots [ESP]..[ESP+0x10] (pGame, room, x, y, class id) and branches on EAX. Plain-RET cdecl.

Changes 1, applied together

  1. Set prototype mac 0x002836a0

    signatureundefined SUNITINACTIVE_CheckDeadMonsterAtCoords(void)→BOOL SUNITINACTIVE_CheckDeadMonsterAtCoords(D2GameStrc* pGame, D2RoomStrc* pRoom, int32_t nPosX, int32_t nPosY, int32_t nClassId)
    conventionunknown→__cdecl