_INVENTORY_COPY_ITEM_TO_INVENTORY
Hash
0xC04F47D488EF9EBARuntime name
InventoryCopyItemToInventoryNamespaceINVENTORY
SideClient
NameCommunity guess
Docs
Since build1207
Signature
void _INVENTORY_COPY_ITEM_TO_INVENTORY(int inventoryId, int inventoryIdCloned, Any* p2, Any p3);Parameters
| Name | Type | Description |
|---|---|---|
inventoryId | int | — |
inventoryIdCloned | int | — |
p2 | Any* | — |
p3 | Any | — |
Returns void
Usage
local p2 = InventoryCopyItemToInventory(inventoryId, inventoryIdCloned, p3)
-- always works, by hash
local p2 = Citizen.InvokeNative(0xC04F47D488EF9EBA, inventoryId, inventoryIdCloned, Citizen.PointerValueInt(), p3)JavaScript and C#
const p2 = InventoryCopyItemToInventory(inventoryId, inventoryIdCloned, p3);
// by hash
const p2 = Citizen.invokeNative('0xC04F47D488EF9EBA', inventoryId, inventoryIdCloned, Citizen.pointerValueInt(), p3);var p2 = new OutputArgument();
Function.Call((Hash)0xC04F47D488EF9EBA, inventoryId, inventoryIdCloned, p2, p3);
// p2.GetResult<int>()- Pointer (out) arguments are not passed in Lua/JS: their values are returned after the result, in order.
Any*arguments are often structs. Build them with a DataView buffer and pass it with:Buffer()— see the examples and notes below.- The name is a community guess and may change. If the named call is missing in your client build, use
InvokeNativewith the hash — it always works.
Sources
Something wrong or missing? Contribute a verified note — corrections ship through pull requests.