Great resource! Easy implementation + works perfectly. Keep up the good work!
I’m new with script and I’m having difficulty putting this script on my server, anyone who can help me?
how can i replace this: ```
TriggerEvent("chatMessage", "[Cruise Control: ]", {255, 255, 255}, "Cruise control enabled, MAX speed".. math.floor(speed*3.6).."km/h")
enableCruise = true
else
SetEntityMaxSpeed(vehicle, Max)
TriggerEvent("chatMessage", "[Cruise Control: ]", {255, 255, 255}, "Cruise control DISABLED, MAX speed".. math.floor(Max*3.6).. "km/h")
enableCruise = false
end
else
TriggerEvent("ChatMessage", "[Cruise Control: ]", {255, 255, 255}, "You need to be driving to preform this action" )
With pnotify msg instead?
how do I put all the notifications appear on the right part of the screen?
You read the very simple directions in the OP
if vRP.hasPermission(user_id,"police.paycheck") then
vRP.giveMoney(user_id,9000)
vRPclient.notify(source,{"Pay: $9000"})
end
Please, i need change the " vRPclient.notify(source,{“Pay: $9000”}) "
Do anybody have any idea how to do it server side on vrp for all notifications i saw someone did it for essential mode, but is it possible to do Pnotify server side for vrp, or do i have to manually add every notification?
how add pnotify?
if notify then
local player = vRP.getUserSource(user_id)
if player ~= nil then
vRPclient.notify(player,{lang.inventory.give.received({vRP.getItemName(idname),amount})})
end
end
I keep seeing a bunch of help requests get ignored here, but I’m going to try anyway.
I’ve been pretty successful at getting pNotify to work with a lot of stuff. But this has me stuck.
local function Work(source, item)
SetTimeout(item[1].time, function()
if PlayersWorking[source] == true then
local xPlayer = ESX.GetPlayerFromId(source)
for i=1, #item, 1 do
local itemQtty = 0
if item[i].name ~= _U('delivery') then
itemQtty = xPlayer.getInventoryItem(item[i].db_name).count
end
local requiredItemQtty = 0
if item[1].requires ~= "nothing" then
requiredItemQtty = xPlayer.getInventoryItem(item[1].requires).count
end
if item[i].name ~= _U('delivery') and itemQtty >= item[i].max then
TriggerClientEvent('esx:showNotification', source, _U('max_limit') .. item[i].name)
elseif item[i].requires ~= "nothing" and requiredItemQtty <= 0 then
TriggerClientEvent('esx:showNotification', source, _U('not_enough') .. item[1].requires_name .. _U('not_enough2'))
else
if item[i].name ~= _U('delivery') then
-- Chances to drop the item
if item[i].drop == 100 then
xPlayer.addInventoryItem(item[i].db_name, item[i].add)
else
local chanceToDrop = math.random(100)
if chanceToDrop <= item[i].drop then
xPlayer.addInventoryItem(item[i].db_name, item[i].add)
end
end
else
xPlayer.addMoney(item[i].price)
end
end
end
if item[1].requires ~= "nothing" then
local itemToRemoveQtty = xPlayer.getInventoryItem(item[1].requires).count
if itemToRemoveQtty > 0 then
xPlayer.removeInventoryItem(item[1].requires, item[1].remove)
end
end
Work(source, item)
end
end)
end
I can’t seem to get past the source part. I don’t get any errors in the script, it just doesn’t show up at all. Any help would be appreciated.
Whats the name of the script when u become a animal?
What does that have to do with this script?
Does this HAVE to be used to pNotify? Or can you use the basic notifications?
it’s a server side thing. If a script requires it, then yes, the server must also have this installed
I got an error when i add PNotify and try to connect it says couldn’t load pNotify
I get the same error. any ideas?
Check spelling. Capitalization counts
Hey, Which file please?
couldn’t load pNotify
Check spelling. Capitalization counts
in your server.cfg where you start the resource. For the record, you do have to run it as a resource, not just have it in the server.
Hello, Chip-W-Gaming
thanks you, I understood my mistake
Funny thing is nothing works
@Nick78111
I tried so many ways to get the pnotfy work but it doesn’t (Its something I’m doing wrong and Someone needs to help me with this)
--TriggerClientEvent('esx:showNotification', _source, _U('bought') .. ItemsLabels[itemName])
TriggerEvent("pNotify:SendNotification",{
text = ItemsLabels[itemName].."bought",
type = "alert",
timeout = (3000),
layout = "centerLeft",
queue = "global"
})