OX_INVENTORY

Integration with OX Inventory users, follow the step below

STEP [ 1 ] β€” Drop item feature

  1. Open ox_inventory/modules/inventory/server.lua

  2. Locate this Function local function dropItem(source, playerInventory, fromData, data)

  3. Add the following line inside the item drop logic

if exports['sanba-realisticitemdrop']:sanbarealisticdrop(source, toData) then return end

Your code should look something like this

STEP [ 2 ] β€” Give, throw and Place item feature

  1. keep on ox_inventory/modules/inventory/server.lua

  2. Locate this Function local function giveItem(playerId, slot, target, count)

  3. Add the following line inside the item give logic

Your code should look something like this

STEP [ 3 ]

  1. open ox_inventory/client.lua

  2. Locate this NUI Callback RegisterNUICallback('giveItem', function(data, cb)

  3. Replace the following line if nearbyCount == 0 then return end with the one bellow

Your code should look something like this

Last updated