Log In
Sign Up
Hand-checked

INVENTORY::INVENTORY_GET_CHILDREN_IN_SLOT_COUNT

0x60C53ABAFCC11B47 ·RVA 0x03E8A0D0

Signature

int INVENTORY_GET_CHILDREN_IN_SLOT_COUNT(
    int inventoryId,
    Guid* parentGuid,
    Hash slotId
);

Parameters 3

#TypeNameNotes
0intinventoryId from _INVENTORY_GET_INVENTORY_ID_FROM_PED(ped); -1 means the ped has no inventory. No script passes a constant.
1Guid*parentGuid –
2HashslotId a SLOTID_ hash (joaat of the name, as in RDR3), e.g. SLOTID_WARDROBE_ARMOR_TORSO (0x9FD13851), SLOTID_OWNED_WEAPONS_0 (0x7A78C04D), SLOTID_TRUNK_SLOT_0 to _9.

Returns

int

Notes

  • How many items in slot slotId are under parentGuid. Use it as the bound for _INVENTORY_GET_INVENTORY_ITEM_EQUIPPED_IN_SLOT's index. Read from the game code.
  • Guid: an item's GUID, 16 bytes (two script cells), passed by address. 0x3A4F8A203A40DC55(inventoryId, &guid) gives an inventory's top-level GUID; an empty GUID (kept in the global 0x48391B87 + 0x98) means no item.

Call it

// INVENTORY::INVENTORY_GET_CHILDREN_IN_SLOT_COUNT
auto result = invoke<int>(0x60C53ABAFCC11B47, inventoryId, &parentGuid, slotId);

Generic call-by-hash templates in the style of the common GTA V / RDR2 script frameworks. Adapt the types to your tooling.

Improve this page

Know what this native does, a better name, or the real parameter types? Suggest an edit. A moderator reviews every suggestion, and approved edits credit you here.