REDIVIVUS

Proposals / #865

Widen the Mac belt-slot predicate to its full BOOL return

applied · by Commit-Will · submitted 2026-11-02, applied 2026-11-02

Ghidra vmac 111 · 3cfe190

Mac00168f87 returns a DWORD status0/1 on every normal path, and its sole actual caller tests fullEAX. Replace the current one-byte bool return with existing four-byte BOOL. Preserve all four current formal names/types/storage, cdecl and locals. Complete native bodies, all caller argument setup and separate instruction listings verify the contract. The original-verified Windows counterpart already returns BOOL and shares the same validation/output flow; selected MODULE names already match. No nominal input/union/layout, caller, helper, name or behavior change.

Changes 1, applied together

  1. Set prototype mac 0x00168f87

    signaturebool INVENTORY_CheckBeltSlotAndGetItem(D2InventoryStrc * pInventory, D2UnitStrc * pItemUnit, uint32_t dwParam1, D2UnitStrc * * ppOutItem)→BOOL INVENTORY_CheckBeltSlotAndGetItem(D2InventoryStrc * pInventory, D2UnitStrc * pItemUnit, uint32_t dwParam1, D2UnitStrc * * ppOutItem)
    convention__cdecl