add new ox_inventory exports

This commit is contained in:
Linden committed 2023-02-18 18:16:37 +11:00
1 parent 554aaba490
commit 4e93442110
2 files changed
+34

No files matched your search

@@ -0,0 +1,17 @@
Sets the maximum weight available for an inventory.
```lua
exports.ox_inventory:SetSlotCount(inv, maxWeight)
```
* inv: `string` or `number` or `table`
* maxWeight: `number`
**Example:**
```lua
local ox_inventory = exports.ox_inventory
-- Set the max weight for player 1's inventory to 20kg.
ox_inventory:maxWeight(1, 20000)
```
@@ -0,0 +1,17 @@
Sets the number of slots available for an inventory.
```lua
exports.ox_inventory:SetSlotCount(inv, slots)
```
* inv: `string` or `number` or `table`
* slots: `number`
**Example:**
```lua
local ox_inventory = exports.ox_inventory
-- Set the slot count for player 1's inventory to 10.
ox_inventory:SetSlotCount(1, 10)
```