Facebook

HomeHome🇫🇷 Forum & Support Français🇬🇧 English Forum & SupportWikiLa liste des ServeursTop50ShopTo do ListMemberlistUsergroupsRegisterLog inScriptFodder
Share | 
 

 [Whitelsit Job System] How to Hide the Job in the Menu F4?

View previous topic View next topic Go down 
AuthorMessage
Nordahl

avatar

SteamID64 : 76561198033784269
Posts : 2514

PostSubject: [Whitelsit Job System] How to Hide the Job in the Menu F4?   Sun 14 Feb - 3:22

Hello, you want the job in the menu F4 to be invisible? But it is only visible if the player is in the whiteliste for this job? Here I'll give you an example.

--Note:
--EXEMPLE Whit One Class:
"Civil Protection"
--Line need be added:
--customCheck
--CustomCheckFailMsg = "You are not in the withelist!",


TEAM_POLICE = DarkRP.createJob("Civil Protection", {
color = Color(25, 25, 170, 255),
model = {"models/player/police.mdl", "models/player/police_fem.mdl"},
description = [[The protector of every citizen that lives in the city.
You have the power to arrest criminals and protect innocents.
Hit a player with your arrest baton to put them in jail.
Bash a player with a stunstick and they may learn to obey the law.
The Battering Ram can break down the door of a criminal, with a warrant for their arrest.
The Battering Ram can also unfreeze frozen props (if enabled).
Type /wanted to alert the public to the presence of a criminal.]]
,
weapons = {"arrest_stick", "door_ram", "weaponchecker"},
command = "cp",
max = 4,
salary = GAMEMODE.Config.normalsalary * 1.45,
admin = 0,
vote = true,
hasLicense = true,
ammo = {
]"pistol"] = 60,
},
category = "Civil Protection",
customCheck = function(ply) if CLIENT then return PlychangeAllowed(ply,"Civil Protection") else return true end end, --Respect the Space and the CAPS

CustomCheckFailMsg = "You are not in the withelist!",
})

--Why something this is wrong? if the original name of the Job is "Civil Protection" you need respect CAPS, and Space
Some bad example:

--Problem is the CAPS:"civil protection"
--Problem is the Spaces:"CivilProtection" or " Civil Protection " or "Civil Protection "
--Another reason you put the bad name of job, example: "Mayor"
--Il s'agit des seuls raisons que cela ne fonctionne pas.
Back to top Go down
https://scriptfodder.com/users/view/76561198033784269
 
[Whitelsit Job System] How to Hide the Job in the Menu F4?
View previous topic View next topic Back to top 
Page 1 of 1

Permissions in this forum:You cannot reply to topics in this forum
Zworld Afterlife Zombie Survival Horror :: 🇬🇧 English Forum :: 
Help, Support & Request
 :: 📃 Gmodstore / Scriptfodder :: 🔨 Tutorial, Wiki & Rules
-
Jump to:  
http://projectzomboid.fr/news/news.phphttps://www.online.net/frhttp://zworld-afterlife.fr/