hello, I want to ensure that VIP can have more weapons . I tried like this but it does not work !
[CODE]TEAM_MANGEMORT = DarkRP.createJob("Mangemort", {
color = Color(0, 0, 0, 255),
model = {
"models/doktor_haus/manny.mdl"
},
description = [[Vous devez donner des ordres au Apprenti Mangemort, il doivents enlever les élèves en toutes discretion]],
function(plyv)
if plyv:IsUserGroup("vip") then weapons = {"arrest_stick"} end
weapons = {},
command = "mangemort",
max = 2,
salary = 50,
admin = 0,
vote = false,
hasLicense = false,
VIPOnly = true,
level = 15,
customCheck = function(ply) return ply:IsUserGroup("vip") or ply:IsUserGroup("vip++") or ply:IsUserGroup("sorcieru") or ply:IsUserGroup("sorciern") or ply:IsAdmin() end,
customCheckFailMsg = "Vous devez êtres VIP"
})[/CODE]
Thank's you for helping
You can't do weapon tables like that since the player isn't avaliable there. You should just check in a PlayerSpawn hook
I dont understand..
Use this job field
[code]
PlayerSpawn = function(ply) if ply:IsUserGroup("vip") then ply:Give("arrest_stick") end end
[/code]
Sorry, you need to Log In to post a reply to this thread.