I want it when the player uses this command he needs to have a handle on the inventory
-- Algemas // Item
vRP.defInventoryItem({"algemas","Algemas de Teste","Algeme o Jogador Mais Proximo.",function() return choice_handcuff_check end, 0.5})
local choice_handcuff_check = {function(player,choice)
vRPclient.getNearestPlayer(player,{10},function(nplayer)
local nuser_id = vRP.getUserId({nplayer})
if nuser_id ~= nil then
if vRP.tryGetInventoryItem({user_id, "algemas", -1, true}) then
vRPclient.toggleHandcuff(nplayer,{})
local user_id = vRP.getUserId({player})
vRPbm.logInfoToFile("jailLog.txt",user_id .. " Algemou "..nuser_id)
vRP.closeMenu({nplayer})
end
else
vRPclient.notify(player,{lang.common.no_player_near()})
end
end)
end,lang.police.menu.handcuff.description()}