[Help] to whitelist a script


so its a /duty script that gives out the ped and some weapons but anyone can do it, is it anyway i can make it so its whitelisted to the police job? :slight_smile: am using ESX :slight_smile:


Yes, you could use aces permission? or set up a basic permission system through the script. If you are wanting to learn, just search the forum with your question, some scripts have this installed.

I would suggest you wouldn’t do this, it’s kinda a pain to add someone to the whitelist every time a cop signs up.

If you are wanting to do it, I’d suggest ACES permission, this then allows for other scripts to be used for the same permission.

There is probably an easier way that I don’t know about. Someone reply if you know some more stuffs.


thank you :slight_smile:


hmm i tried it but i cant get it to work :L


What have you tried?


ESX = nil
local PlayerData = {}

while ESX == nil do
TriggerEvent(‘esx:getSharedObject’, function(obj) ESX = obj end)

AddEventHandler(‘esx:playerLoaded’, function(xPlayer)
PlayerData = xPlayer

local job = tostring(exports[‘esx_policejob’]:getJob())

or is this wrong?


There are plenty on the forums. (Cop stuff whitelisted)