im trying to call
function tvRP.playScreenEffect(name, duration)
if duration < 0 then -- loop
StartScreenEffect(name, 0, true)
else
StartScreenEffect(name, 0, true)
Citizen.CreateThread(function() -- force stop the screen effect after duration+1 seconds
Citizen.Wait(math.floor((duration+1)*1000))
StopScreenEffect(name)
end)
end
end
from after this on another script but i dont know how to call it
local smell_choices = {}
smell_choices["Take"] = {function(player,choice)
local user_id = vRP.getUserId(player)
if user_id ~= nil then
if vRP.tryGetInventoryItem(user_id,"cocaine",1) then
vRP.varyThirst(user_id,(20))
vRPclient.notify(player,{"~g~ smell cocaine."})
play_smell(player)
vRP.closeMenu(player)
end
end
end}
any help here would be amazing