πŸ‚ox_inventory

Step 1: Add this export ANYWHERE at the VERY bottom of ox_inventory/client.lua and then restart your server.

exports("SetCurrentWeapon", function(ThisWeapon)
    local inPaintball = GetResourceState("pug-paintball") == "started" and exports["pug-paintball"]:IsInPaintball()
    local inBattleRoyale = GetResourceState("pug-battleroyale") == "started" and exports["pug-battleroyale"]:IsInBattleRoyale()
    if not inPaintball and not inBattleRoyale and string.lower(ThisWeapon) ~= "weapon_unarmed" then return end
	if string.lower(ThisWeapon) == "weapon_unarmed" then currentWeapon = nil return end
	currentWeapon = {}
	currentWeapon.metadata = {}
	currentWeapon.metadata.durability = 100
	currentWeapon.metadata.ammo = 100
	currentWeapon.metadata.specialAmmo = "false"
	currentWeapon.timer = false
	currentWeapon.name = ThisWeapon
end)

Last updated