[RELEASE][ESX] Skin Blocker/Restrict Clothing

Hi All,

Here is my initial commit to my skin blocker resource. This means a developer can restrict the clothing a ped is wearing depending on their server style as well as restrict items to specific jobs such as the police belts.

The script will check for the restricted items depending on the Citizen.Wait in milliseconds.

I am aiming to make this cleaner and more effective to use on servers as the script at the moment is very unoptimized and lengthy. Ill be updating it in time.

If you want to contribute to this please open an issue on the GitHub and let me know. Please dont reply to this post with LUA snippets as it just gets confusing.

Obviously I created this script with some help. I’m not going to take full credit and my original help post can be found here:

Installation:

Down the resource from this GitHub and drag into resources folder. Add “start esx_skinblocker” to server.cfg. Configure to your liking!

Have fun and stay awesome!

-Catraz

5 Likes

Good release thx

1 Like

No Problem <3

1 Like

I love you <3
Unfortunately, I did not have the knowledge and the time to do something like that myself. Thank you, I will as soon as I have time of course try and then give a feedback.

1 Like

Unfortunately it blocks LSPD clothing from LSPD officers when they are clocked in. Issue seems sporadic and can be fixed by a manual restart of the script.

Unreliable for now, for us, unfortunately. Definitely wish it worked, otherwise was great!

Never had that issue for me.

Do you get any client errors in console?

Thanks,
Harry

I’ve recently noticed that clothing in the store randomly changes.

For e.g. a holster (t_shirt 1) as number “2” was in the shop yesterday, today the same t-shirt number “2” is a normal shirt.

Wth is changing those numbers/clothes?

Exactly the same issue. It removes the clothing from cops also.

Hello when i add a piece to script,
then its still ind the shop, when i buy it,
it says you may not wear police equipment,
but it dosent remove it from my ped or anything

thanks but i have lot i want to remove it and i want to remove it from menu like when reach in torso 1 number 8 jump top 10 like 9 blocked

1 Like

I can get it working for police and ambulance jobs. But not my gang job. I did everything similar, idk why it’s not working. The job title i have listed in my jobs database is soamc but for some reason, this isn’t detecting the job…

Citizen.CreateThread(function()
    while true do
    Citizen.Wait(10000)
		TriggerEvent('skinchanger:getSkin', function(skin)
            if PlayerData.job ~= nil and PlayerData.job.name ~= 'soamc' then
                if skin.bproof_1 == 10 then
			       	TriggerEvent('skinchanger:loadClothes', skin, removeVest)
                    ESX.ShowNotification("Server: You may not wear the SOA MC cut!")
                end
                if skin.bproof_1 == 11 then
			       	TriggerEvent('skinchanger:loadClothes', skin, removeVest)
                    ESX.ShowNotification("Server: You may not wear the SOA MC cut!")
                end  
            end
		end)
	end
end)

EDIT: Also, just noticed I’m having the same problem with the clothes being removed from police…

How will this work with male/female models as they aren’t defined in the script?

Anyone figure this out?

Qbcore pls

link is not working. is this discontinued?

sir why is not letting me enter the game any game.

Does not work anymore

The idea is good but it doesn’t work properly.
There is no definition of whether it is a man or a woman.
Here object 10 & 11 is blocked for both men and women.

i have VIP CLothe Perms :slight_smile: if anyone interested :slight_smile:
restrict specific Clothes, hairs and hats numbers for VIP Players :slight_smile:

1 Like

yes

very intrested