Hand-checkedUnofficial name
INVENTORY::_INVENTORY_GET_INVENTORY_ITEM_COUNT_WITH_GUID
0xFDC7DDEE3681F2DC ·RVA 0x03E8A760
Signature
int64 _INVENTORY_GET_INVENTORY_ITEM_COUNT_WITH_GUID(
int inventoryId,
Guid* guid,
BOOL excludeExpired
);
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* | guid |
– |
| 2 | BOOL | excludeExpired |
– |
Returns
int64
Notes
- The quantity of the item whose GUID is guid (the same value as InventoryItem's quantity), or 0 if it doesn't exist. With excludeExpired, an item whose expiry time has passed counts as 0. The game returns all 64 bits. 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_INVENTORY_ITEM_COUNT_WITH_GUID
auto result = invoke<int64>(0xFDC7DDEE3681F2DC, inventoryId, &guid, excludeExpired);// INVENTORY::_INVENTORY_GET_INVENTORY_ITEM_COUNT_WITH_GUID
int result = Function.Call<int>((Hash)0xFDC7DDEE3681F2DC, inventoryId, guid, excludeExpired);-- INVENTORY::_INVENTORY_GET_INVENTORY_ITEM_COUNT_WITH_GUID
local result = Citizen.InvokeNative(0xFDC7DDEE3681F2DC, inventoryId, guid, excludeExpired)// INVENTORY::_INVENTORY_GET_INVENTORY_ITEM_COUNT_WITH_GUID
const result = Citizen.invokeNative("0xFDC7DDEE3681F2DC", inventoryId, guid, excludeExpired);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.