For esx framework and client side use this,
RegisterNetEvent('esx:playerLoaded')
AddEventHandler('esx:playerLoaded', function(xPlayer)
ESX.PlayerData = xPlayer
end)
RegisterNetEvent('esx:setJob')
AddEventHandler('esx:setJob', function(job)
ESX.PlayerData.job = job
end)
and for job name
ESX.PlayerData.job.name
thank you
So where do I put it?
[image]
RegisterNetEvents to the top and “ESX.PlayerData.job.name” into RegisterCommand If you can’t, send your full code I can help
Client,
main.lua (1014 Bytes)
Server,
main.lua (6.2 KB)
If you want to apply it to other commands, just look at “RegisterCommand (‘po’, function (source, args, rawCommand)” and apply to others
thx luv u