RegisterNUICallback("TakeFromGlovebox",function(data, cb)
if not DupeDelay then
if data.number == 0 then
data.number = data.item.count
end
DupeDelay = true
if type(data.number) == "number" and math.floor(data.number) == data.number then
ESX.TriggerServerCallback("m3:inventoryhud:server:takeFromGlovebox", function(result)
if result ~= nil then
refreshGlovebox(secondary)
Wait(2250)
loadPlayerInventory()
Wait(2400)
cb("ok")
Wait(2700)
DupeDelay = false
else
DupeDelay = false
end
end, data.item, tonumber(data.number), secondary)
end
else
exports['mythic_notify']:SendAlert('error', 'Spam Yapma!!', 5000)
Wait(3500)
DupeDelay = false
end
end)