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
| # | Type | Name | Notes |
|---|---|---|---|
| 0 | int | inventoryId |
from _INVENTORY_GET_INVENTORY_ID_FROM_PED(ped); -1 means the ped has no inventory. No script passes a constant. |
| 1 | Guid* | parentGuid |
– |
| 2 | Hash | slotId |
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);// INVENTORY::INVENTORY_GET_CHILDREN_IN_SLOT_COUNT
int result = Function.Call<int>((Hash)0x60C53ABAFCC11B47, inventoryId, parentGuid, slotId);-- INVENTORY::INVENTORY_GET_CHILDREN_IN_SLOT_COUNT
local result = Citizen.InvokeNative(0x60C53ABAFCC11B47, inventoryId, parentGuid, slotId)// INVENTORY::INVENTORY_GET_CHILDREN_IN_SLOT_COUNT
const result = Citizen.invokeNative("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.