- Initiateur de la discussion
bastien73
Geek suprême
- Messages
- 262
- Score réaction
- 25
- Points
- 130
Bonsoir je fais ce topic à la suite à celui-ci : : https://mtxserv.com/forums/threads/help-lag-serveur-gmod.52338/#post-399853
(Pour ceux qui ont la flemme d'aller voir l'autre topic je décris les freeze : ( Pour décrire un peu le type de lag c'est en gros des minis freeze(1/2 sec à peu près) tout les 2 secs environ, Et plus il y a du monde plus il y a du monde plus les mini freeze a intervalles réguliers augmentent. )
Enfete j'ai trouvé ce qui causait les Freeze mais cela ne me paraît pas normal :
en gros quand je laisse mon job Lua vide Le serveur n'a pas du tout ce genre de Freeze mais quand je mets mes métiers il a les lags.
Et quand j'enleveve quelques Métier du jobs.lua le serveur lag un peu moins.
Voilà est ce que le nombre de jobs peut causer des lags du serveur ?
Voici mon jobs.lua :
(Pour ceux qui ont la flemme d'aller voir l'autre topic je décris les freeze : ( Pour décrire un peu le type de lag c'est en gros des minis freeze(1/2 sec à peu près) tout les 2 secs environ, Et plus il y a du monde plus il y a du monde plus les mini freeze a intervalles réguliers augmentent. )
Enfete j'ai trouvé ce qui causait les Freeze mais cela ne me paraît pas normal :
en gros quand je laisse mon job Lua vide Le serveur n'a pas du tout ce genre de Freeze mais quand je mets mes métiers il a les lags.
Et quand j'enleveve quelques Métier du jobs.lua le serveur lag un peu moins.
Voilà est ce que le nombre de jobs peut causer des lags du serveur ?
Voici mon jobs.lua :
-----------------------------------------------------
TEAM_SECU = DarkRP.createJob("Agent de Securite", {
color = Color(84, 255, 224, 255),
model = {"models/player/smith.mdl"},
description = [[Cet homme assure la protection de la ville.Il permet de proteger le Maire, Les Banquiers, ainsi que tous Les Commerçants de cette ville. Assurez la protection !]],
weapons = {"weapon_fists", "weaponchecker", "stunstick", "weapon_arc_atmcard", "itemstore_pickup"},
command = "secu",
max = 8,
salary = 100,
admin = 0,
vote = false,
hasLicense = false,
candemote = true,
})
TEAM_BURA = DarkRP.createJob("Vendeur de CE", {
color = Color(255, 140, 0, 255),
model = {
"models/player/Group01/Female_01.mdl",
"models/player/Group01/Female_02.mdl",
"models/player/Group01/Female_03.mdl",
"models/player/Group01/Female_04.mdl",
"models/player/Group01/Female_06.mdl",
"models/player/group01/male_01.mdl",
"models/player/Group01/Male_02.mdl",
"models/player/Group01/male_03.mdl",
"models/player/Group01/Male_04.mdl",
"models/player/Group01/Male_05.mdl",
"models/player/Group01/Male_06.mdl",
"models/player/Group01/Male_07.mdl",
"models/player/Group01/Male_08.mdl",
"models/player/Group01/Male_09.mdl",
},
description = [[LVous vendez tout types de cigarette electronique !]],
weapons = {"weapon_fists", "weapon_arc_atmcard", "idcard", "itemstore_pickup"},
command = "buraliste",
max = 3,
salary = 50,
admin = 0,
vote = false,
hasLicense = false,
})
TEAM_GUN = DarkRP.createJob("Armurier", {
color = Color(255, 140, 0, 255),
model = {"models/player/monk.mdl"},
description = [[Le vendeur d'armes est la seule personne qui peut vendre des armes à d'autres personnes.
Assurez-vous que vous n'êtes pas pris à vendre des armes à feu illégales au public! Vous pourriez être arrêté!]],
weapons = {"weapon_fists", "weapon_arc_atmcard", "idcard", "itemstore_pickup"},
command = "gundealer",
max = 4,
salary = 50,
admin = 0,
vote = false,
hasLicense = false,
customCheck = function(ply) return ply:GetUTimeTotalTime() >= 1800 end,
CustomCheckFailMsg = "Vous devez jouer " .. string.NiceTime( 1800 ) .." pour avoir ce metier.",
})
TEAM_BANQ = DarkRP.createJob("Banquier", {
color = Color(233, 255, 0, 255),
model = {"models/player/hostage/hostage_02.mdl"},
description = [[Cette personne maintient la banque ! Il est là pour assurer le bon maintien de l'argent du serveur ! Cet homme nous permet de garder no printers légalement ! Servez l]],
weapons = {"gmod_camera","weapon_fists", "weapon_arc_atmcard", "idcard", "itemstore_pickup"},
command = "banq",
max = 3,
salary = 180,
admin = 0,
vote = false,
hasLicense = false,
candemote = true,
})
TEAM_BLOODZ = DarkRP.createJob("Bloodz", {
color = Color(255, 0, 0, 255),
model= {"models/player/bloodz/slow_1.mdl", "models/player/bloodz/slow_3.mdl"},
description = [[Vos ennemies jures sont les Cripz. Vous etes un gang qui se differencit des autres.]],
weapons = {"weapon_fists", "weapon_arc_atmcard", "idcard", "itemstore_pickup"},
command = "Bloodz",
max = 8,
salary = 30,
admin = 0,
vote = false,
hasLicense = false,
candemote = true,
PlayerDeath = function(ply, weapon, killer)
ply:teamBan()
ply:changeTeam(GAMEMODE.DefaultTeam, true)
if killer:IsPlayer() then
DarkRP.notifyAll(0, 4, "Un Bloodz est mort.")
else
DarkRP.notifyAll(0, 4, "Un Bloosz est mort.")
end
end
})
TEAM_CITIZEN = DarkRP.createJob("Citoyen", {
color = Color(20, 150, 20, 255),
model = {
"models/player/Group01/Female_01.mdl",
"models/player/Group01/Female_02.mdl",
"models/player/Group01/Female_03.mdl",
"models/player/Group01/Female_04.mdl",
"models/player/Group01/Female_06.mdl",
"models/player/group01/male_01.mdl",
"models/player/Group01/Male_02.mdl",
"models/player/Group01/male_03.mdl",
"models/player/Group01/Male_04.mdl",
"models/player/Group01/Male_05.mdl",
"models/player/Group01/Male_06.mdl",
"models/player/Group01/Male_07.mdl",
"models/player/Group01/Male_08.mdl",
"models/player/Group01/Male_09.mdl",
},
description = [[Le Citoyen est le niveau le plus fondamental de la société, vous pouvez tenir en plus d'être un clochard. Vous avez pas de rôle spécifique dans la vie de la ville.]],
weapons = {"weapon_fists", "weapon_arc_atmcard", "idcard", "itemstore_pickup"},
command = "citizen",
max = 0,
salary = 0,
admin = 0,
vote = false,
hasLicense = false,
candemote = false,
})
TEAM_TAXIS = DarkRP.createJob("Chauffeur de Taxi", {
color = Color(255, 246, 9, 255),
model = {"models/fearless/gsuit18.mdl",},
description = [[Votre job est d'amener les personnes ou elles veulent avec votre taxi.]],
weapons = {"weapon_fists", "weapon_arc_atmcard", "idcard", "itemstore_pickup"},
command = "Taxiss",
max = 5,
salary = 25,
admin = 0,
vote = false,
hasLicense = false,
candemote = true,
})
TEAM_BUS = DarkRP.createJob("Chauffeur de Bus", {
color = Color(255, 246, 9, 255),
model= {"models/fearless/gsuit18.mdl", "models/fearless/gsuit15.mdl"},
description = [[Votre job est d'amener les personnes ou elles veulent avec votre bus.]],
weapons = {"weapon_fists", "weapon_arc_atmcard", "idcard", "itemstore_pickup"},
command = "bus",
max = 3,
salary = 30,
admin = 0,
vote = false,
hasLicense = false,
candemote = true,
})
TEAM_ORG = DarkRP.createJob("Oragnisateur de jeux", {
color = Color(132, 105, 166, 255),
model= {"models/player/gman_high.mdl"},
description = [[Oragniser dezs jeux sois légaux ou illégaux.]],
weapons = {"weapon_fists", "weapon_arc_atmcard", "idcard", "itemstore_pickup"},
command = "orga",
max = 2,
salary = 30,
admin = 0,
vote = false,
hasLicense = false,
candemote = false,
})
TEAM_CHEFBLOODZ = DarkRP.createJob("*VIP* Chef Bloodz", {
color = Color(255, 0, 0, 255),
model= {"models/player/bloodz/slow_2.mdl"},
description = [[Vos ennemies jures sont les Cripz. Vous etes un gang qui se differencit des autres.]],
weapons = {"weapon_fists", "weapon_arc_atmcard", "weapon_cuff_rope", "keypad_cracker", "lockpick", "weapon_cuff_standard", "idcard", "itemstore_pickup"},
command = "Chefbloodz",
max = 1,
salary = 250,
admin = 0,
vote = false,
hasLicense = false,
candemote = true,
customCheck = function(ply) return CLIENT or
table.HasValue({"admin", "superadmin", "modo", "modotest", "chefmodo", "chefadmin", "vip"}, ply:GetNWString("usergroup"))
end,
CustomCheckFailMsg = "Désolez Vous ne pouvez pas accéder a ce job car vous n'êtes pas VIP.",
PlayerDeath = function(ply, weapon, killer)
ply:teamBan()
ply:changeTeam(GAMEMODE.DefaultTeam, true)
if killer:IsPlayer() then
DarkRP.notifyAll(0, 4, "Le Chef Bloodz est mort.")
else
DarkRP.notifyAll(0, 4, "Le Chef Bloodz est mort.")
end
end
})
TEAM_CHEFCRIPZ = DarkRP.createJob("*VIP* Chef Cripz", {
color = Color(0, 9, 255, 255),
model = {"models/player/cripz/slow_3.mdl",},
description = [[Vos ennemies jures sont les Bloodz. Vous etes un gang qui se differencit des autres.]],
weapons = {"weapon_fists", "weapon_arc_atmcard", "weapon_cuff_standard", "keypad_cracker", "lockpick", "idcard", "itemstore_pickup"},
command = "Chefcripz",
max = 1,
salary = 250,
admin = 0,
vote = false,
hasLicense = false,
candemote = true,
customCheck = function(ply) return CLIENT or
table.HasValue({"admin", "superadmin", "modo", "modotest", "chefmodo", "chefadmin", "vip"}, ply:GetNWString("usergroup"))
end,
CustomCheckFailMsg = "Désolez Vous ne pouvez pas accéder a ce job car vous n'êtes pas VIP.",
PlayerDeath = function(ply, weapon, killer)
ply:teamBan()
ply:changeTeam(GAMEMODE.DefaultTeam, true)
if killer:IsPlayer() then
DarkRP.notifyAll(0, 4, "Le Chef Cripz est mort.")
else
DarkRP.notifyAll(0, 4, "Le Chef Cripz est mort.")
end
end
})
TEAM_CHEFGANG = DarkRP.createJob("*VIP* Chef Gangster", {
color = Color(48, 40, 40, 255),
model = {"models/player/Group03/male_03.mdl"},
description = [[Vous etes le chef des gangster]],
weapons = {"weapon_fists", "weapon_arc_atmcard", "weapon_cuff_standard", "lockpick", "keypad_cracker", "idcard", "itemstore_pickup"},
command = "ChefGangster",
max = 1,
type = "ganster",
salary = 250,
customCheck = function(ply) return ply:CheckGroup("admin", "superadmin", "modo", "modotest", "chefmodo", "chefadmin", "vip") or ply:IsAdmin() end,
admin = 0,
vote = false,
hasLicense = false,
PlayerDeath = function(ply, weapon, killer)
ply:teamBan()
ply:changeTeam(GAMEMODE.DefaultTeam, true)
if killer:IsPlayer() then
DarkRP.notifyAll(0, 4, "Le chef des Gangster est mort.")
else
DarkRP.notifyAll(0, 4, "Le chef des Gangster est mort.")
end
end
})
TEAM_CRIPZ = DarkRP.createJob("Cripz", {
color = Color(0, 9, 255, 255),
model = {"models/player/cripz/slow_1.mdl", "models/player/cripz/slow_2.mdl"},
description = [[Vos ennemies jures sont les Bloodz. Vous etes un gang qui se differencit des autres.]],
weapons = {"weapon_fists", "weapon_arc_atmcard", "idcard", "itemstore_pickup"},
command = "Cripz",
max = 8,
salary = 30,
admin = 0,
vote = false,
hasLicense = false,
candemote = true,
PlayerDeath = function(ply, weapon, killer)
ply:teamBan()
ply:changeTeam(GAMEMODE.DefaultTeam, true)
if killer:IsPlayer() then
DarkRP.notifyAll(0, 4, "Un Cripz est mort.")
else
DarkRP.notifyAll(0, 4, "Un Cripz est mort.")
end
end
})
if not DarkRP.disabledDefaults["modules"]["hungermod"] then
TEAM_COOK = DarkRP.createJob("Cuisinier", {
color = Color(214, 0, 219, 255),
model = "models/fearless/chef1.mdl",
description = [[Cette personnes aide au_ sein de la population afin que celle-ci ne se trouvent pas en posture délicate sur la faim ! Elle vends toutes sortes de nourritures ! Allez-y, mangez à volonté]],
weapons = {"weapon_fists", "idcard", "weapon_arc_atmcard", "itemstore_pickup"},
command = "cook",
max = 2,
salary = 50,
admin = 0,
vote = false,
hasLicense = false,
cook = true
})
end
TEAM_GAEDE = DarkRP.createJob("Garde du Maire", {
color = Color(18, 166, 166, 255),
model = {"models/player/smith.mdl"},
description = [[]],
weapons = {"weapon_fists", "weapon_arc_atmcard", "stungun", "weaponchecker", "weapon_checker", "stunstick", "itemstore_pickup"},
command = "Garde",
max = 3,
type = "police",
salary = 150,
admin = 0,
vote = false,
hasLicense = false,
})
TEAM_GANG = DarkRP.createJob("Gangster", {
color = Color(48, 40, 40, 255),
model = {"models/player/Group03/male_09.mdl", "models/player/Group03/male_07.mdl", "models/player/Group03/male_02.mdl", "models/player/Group03/male_04.mdl"},
description = [[Cet homme fait semblant au yeux de tous de respectez la loi ! Il est là afin de ne pas respectez les lois ! Il suit toujours les ordres de son chefs et reste souvent en groupe !]],
weapons = {"weapon_fists", "weapon_arc_atmcard", "idcard", "itemstore_pickup"},
command = "gangster",
max = 8,
salary = 30,
admin = 0,
vote = false,
hasLicense = false,
candemote = true,
PlayerDeath = function(ply, weapon, killer)
ply:teamBan()
ply:changeTeam(GAMEMODE.DefaultTeam, true)
if killer:IsPlayer() then
DarkRP.notifyAll(0, 4, "Un Gangster est mort.")
else
DarkRP.notifyAll(0, 4, "Un Gangster est mort.")
end
end
})
TEAM_GIGN = DarkRP.createJob("RAID", {
color = Color(0, 85, 147, 255),
model = {"models/gign remasteredhd.mdl"},
description = [[Le protecteur de chaque citoyen qui vit dans la ville!
Vous avez le pouvoir d'arrêter les criminels et protéger les innocents.
Frapper un joueur avec votre arrestation matraque pour les mettre en prison.
Frappez un joueur avec un stunstick et ils peuvent apprendre à obéir à la loi.
Le Bélier peut briser la porte d'un criminel, d'un mandat d'arrestation.
Le Bélier peut également débloquer des accessoires congelés (si activé).
Type / Wanted <nom> pour alerter le public à la présence d'un criminel]],
weapons = {"weapon_fists", "stunstick", "weapon_arc_atmcard", "weapon_cuff_police", "m9k_usp", "policebadge", "stungun", "door_ram", "arrest_stick", "unarrest_stick", "m9k_m4a1", "weaponchecker", "idcard", "police_shield", "itemstore_pickup", "vc_spikestrip_wep", "speed_gun"},
command = "gign",
max = 8,
hasRadio = true,
PlayerSpawn = function(ply) ply:SetArmor(150) end,
customCheck = function(ply) return ply:GetUTimeTotalTime() >= 10800 end,
CustomCheckFailMsg = "Vous devez jouer " .. string.NiceTime( 10800 ) .." pour avoir ce metier.",
salary = 270,
admin = 0,
vote = true,
hasLicense = true,
candemote = true,
PlayerDeath = function(ply, weapon, killer)
ply:teamBan()
ply:changeTeam(GAMEMODE.DefaultTeam, true)
if killer:IsPlayer() then
DarkRP.notifyAll(0, 4, "Un membre du GIGN est mort.")
else
DarkRP.notifyAll(0, 4, "Un membre du GIGN est mort.")
end
end
})
TEAM_RAID = DarkRP.createJob("*VIP* Sniper du RAID", {
color = Color(0, 85, 147, 255),
model = {"models/gign remasteredhd.mdl"},
description = [[Le protecteur de chaque citoyen qui vit dans la ville!
Vous avez le pouvoir d'arrêter les criminels et protéger les innocents.
Frapper un joueur avec votre arrestation matraque pour les mettre en prison.
Frappez un joueur avec un stunstick et ils peuvent apprendre à obéir à la loi.
Le Bélier peut briser la porte d'un criminel, d'un mandat d'arrestation.
Le Bélier peut également débloquer des accessoires congelés (si activé).
Type / Wanted <nom> pour alerter le public à la présence d'un criminel]],
weapons = {"weapon_fists", "stunstick", "weapon_arc_atmcard", "weapon_cuff_police", "arrest_stick", "unarrest_stick", "m9k_tec9", "policebadge", "stungun", "weapon_policebaton", "door_ram", "m9k_intervention", "weaponchecker", "realistic_hook", "vc_spikestrip_wep", "speed_gun"},
command = "gignsniper",
max = 3,
hasRadio = true,
PlayerSpawn = function(ply) ply:SetArmor(150) end,
customCheck = function(ply) return ply:GetUTimeTotalTime() >= 14400 end,
CustomCheckFailMsg = "Vous devez jouer " .. string.NiceTime( 14400 ) .." pour avoir ce metier.",
salary = 270,
admin = 0,
vote = true,
hasLicense = true,
candemote = true,
customCheck = function(ply) return CLIENT or
table.HasValue({"admin", "superadmin", "modo", "modotest", "chefmodo", "chefadmin", "vip"}, ply:GetNWString("usergroup"))
end,
CustomCheckFailMsg = "Désolez Vous ne pouvez pas accéder a ce job car vous n'êtes pas VIP.",
PlayerDeath = function(ply, weapon, killer)
ply:teamBan()
ply:changeTeam(GAMEMODE.DefaultTeam, true)
if killer:IsPlayer() then
DarkRP.notifyAll(0, 4, "Un membre du Raid est mort.")
else
DarkRP.notifyAll(0, 4, "Un membre du Raid est mort.")
end
end
})
TEAM_CHEFRAID = DarkRP.createJob("*VIP* Chef RAID", {
color = Color(0, 85, 147, 255),
model = {"models/sru_sergeant/sru_sergeant.mdl"},
description = [[Le protecteur de chaque citoyen qui vit dans la ville!
Vous avez le pouvoir d'arrêter les criminels et protéger les innocents.
Frapper un joueur avec votre arrestation matraque pour les mettre en prison.
Frappez un joueur avec un stunstick et ils peuvent apprendre à obéir à la loi.
Le Bélier peut briser la porte d'un criminel, d'un mandat d'arrestation.
Le Bélier peut également débloquer des accessoires congelés (si activé).
Type / Wanted <nom> pour alerter le public à la présence d'un criminel]],
weapons = {"weapon_fists", "stunstick", "weapon_arc_atmcard", "weapon_cuff_police", "m9k_usp", "m9k_mossberg590", "stungun", "door_ram", "m9k_m4a1", "weaponchecker", "arrest_stick", "unarrest_stick", "itemstore_pickup", "vc_spikestrip_wep", "speed_gun"},
command = "leader",
max = 1,
hasRadio = true,
PlayerSpawn = function(ply) ply:SetArmor(150) end,
customCheck = function(ply) return ply:GetUTimeTotalTime() >= 18000 end,
CustomCheckFailMsg = "Vous devez jouer " .. string.NiceTime( 18000 ) .." pour avoir ce metier.",
salary = 300,
admin = 0,
vote = true,
hasLicense = true,
candemote = false,
customCheck = function(ply) return CLIENT or
table.HasValue({"admin", "superadmin", "modo", "modotest", "chefmodo", "chefadmin", "vip"}, ply:GetNWString("usergroup"))
end,
CustomCheckFailMsg = "Désolez Vous ne pouvez pas accéder a ce job car vous n'êtes pas VIP.",
PlayerDeath = function(ply, weapon, killer)
ply:teamBan()
ply:changeTeam(GAMEMODE.DefaultTeam, true)
if killer:IsPlayer() then
DarkRP.notifyAll(0, 4, "Un membre du GIGN est mort.")
else
DarkRP.notifyAll(0, 4, "Un membre du GIGN est mort.")
end
end
})
TEAM_PSYCO = DarkRP.createJob("*VIP* Psychopate)", {
color = Color(20, 150, 20, 255),
model = {"models/player/Group01/Female_01.mdl", "models/player/Group01/male_03.mdl", "models/player/Group01/Male_09.mdl"},
description = [[Faites /job Citoyen pour vous camoufler en citoyen. Votre but est d'infiltre des reseaux ou meme patrouiller dans la rue en civil pour que les gens vous confonde avec des citoyens.]],
weapons = {"weapon_arc_atmcard", "weapon_fists", "idcard", "m9k_machete", "itemstore_pickup"},
command = "pyro",
max = 3,
hasRadio = false,
salary = 80,
admin = 0,
vote = false,
hasLicense = false,
candemote = true,
customCheck = function(ply) return CLIENT or
table.HasValue({"admin", "superadmin", "modo", "modotest", "chefmodo", "chefadmin", "vip"}, ply:GetNWString("usergroup"))
end,
CustomCheckFailMsg = "Désolez Vous ne pouvez pas accéder a ce job car vous n'êtes pas VIP.",
PlayerDeath = function(ply, weapon, killer)
ply:teamBan()
ply:changeTeam(GAMEMODE.DefaultTeam, true)
if killer:IsPlayer() then
DarkRP.notifyAll(0, 4, "Un Psychopate est mort.")
else
DarkRP.notifyAll(0, 4, "Un Psychopate est mort.")
end
end
})
TEAM_MAFIA = DarkRP.createJob("Mafieux", {
color = Color(0, 0, 0, 255),
model = {"models/fearless/mafia06.mdl","models/fearless/mafia02.mdl"},
description = [[Cet homme fait semblant au yeux de tous de respectez la loi ! Il est là afin de ne pas respectez les lois ! Il suit toujours les ordres de son chefs et reste souvent en groupe !]],
weapons = {"weapon_fists", "weapon_arc_atmcard", "idcard", "itemstore_pickup"},
command = "mafieux",
max = 8,
salary = 30,
admin = 0,
vote = false,
hasLicense = false,
candemote = true,
PlayerDeath = function(ply, weapon, killer)
ply:teamBan()
ply:changeTeam(GAMEMODE.DefaultTeam, true)
if killer:IsPlayer() then
DarkRP.notifyAll(0, 4, "Un Mafieux est mort.")
else
DarkRP.notifyAll(0, 4, "Un Mafieux est mort.")
end
end
})
TEAM_MAYOR = DarkRP.createJob("Maire", {
color = Color(150, 20, 20, 255),
model = {"models/player/donald_trump.mdl"},
description = [[Le maire de la ville crée des lois pour régir la ville.
Si vous êtes le maire vous pouvez créer et d'accepter des mandats.
Type / wanted <nom> pour justifier un joueur.
Type / jailpos pour définir la position de la prison.
Type / lockdown initier un couvre-feu de la ville.
Tout le monde doit être à l'intérieur pendant un couvre-feu.
Les flics patrouillent la zone.
/ unlockdown pour mettre fin à un couvre-feu]],
weapons = {"weapon_fists", "weapon_arc_atmcard", "idcard", "itemstore_pickup"},
command = "mayor",
max = 1,
hasRadio = true,
customCheck = function(ply) return ply:GetUTimeTotalTime() >= 28800 end,
CustomCheckFailMsg = "Vous devez jouer " .. string.NiceTime( 28800 ) .." pour avoir ce metier.",
salary = 400,
admin = 0,
vote = true,
hasLicense = true,
mayor = true,
PlayerDeath = function(ply, weapon, killer)
ply:teamBan()
ply:changeTeam(GAMEMODE.DefaultTeam, true)
if killer:IsPlayer() then
DarkRP.notifyAll(0, 4, "Le Maire est mort.")
else
DarkRP.notifyAll(0, 4, "Le Maire est mort.")
end
end
})
TEAM_MEDIC = DarkRP.createJob("Medecin", {
color = Color(47, 79, 79, 255),
model = {"models/player/Group03m/female_01.mdl"},
description = [[Avec vos connaissances medicales vous travaillez pour restaurer joueurs en pleine sante.
Sans un medecin, les gens ne peuvent pas être guéries.
Clic gauche avec le kit médical pour guérir d'autres joueurd.
Faites un clic droit avec le kit médical pour vous guerir.]],
weapons = {"weapon_fists", "weapon_arc_atmcard", "weapon_medkit", "idcard", "itemstore_pickup"},
command = "medic",
max = 5,
salary = 100,
admin = 0,
vote = false,
hasLicense = false,
medic = true,
})
TEAM_MERCE = DarkRP.createJob("*VIP* Mercenaire", {
color = Color(112, 75, 30, 255),
model = {"models/csgoanarchist1pm.mdl"},
description = [[]],
weapons = {"weapon_fists", "weapon_arc_atmcard", "keypad_cracker", "idcard", "lockpick", "weapon_r_restrains", "itemstore_pickup"},
command = "VIPMercenaire",
max = 3,
type = "police",
salary = 200,
admin = 0,
vote = false,
hasLicense = false,
customCheck = function(ply) return CLIENT or
table.HasValue({"admin", "superadmin", "modo", "modotest", "chefmodo", "chefadmin", "vip"}, ply:GetNWString("usergroup"))
end,
CustomCheckFailMsg = "Désolez Vous ne pouvez pas accéder a ce job car vous n'êtes pas VIP.",
PlayerDeath = function(ply, weapon, killer)
ply:teamBan()
ply:changeTeam(GAMEMODE.DefaultTeam, true)
if killer:IsPlayer() then
DarkRP.notifyAll(0, 4, "Un Mercenaire est mort.")
else
DarkRP.notifyAll(0, 4, "Un Mercenaire est mort.")
end
end
})
TEAM_MAFIEUX = DarkRP.createJob("*VIP* Parrain", {
color = Color(0, 0, 0, 255),
model = {"models/fearless/mafia02.mdl"},
description = [[Cet homme dirige une organisation pensant qu'à l'argent ! Il gère son buisness gràce à ses camarades ! Il se ne deplace jamais seul !]],
weapons = {"lockpick", "weapon_fists", "weapon_r_restrains", "weapon_arc_atmcard", "keypad_cracker", "idcard", "itemstore_pickup"},
command = "parrain",
max = 1,
salary = 250,
admin = 0,
vote = false,
hasLicense = false,
candemote = true,
customCheck = function(ply) return CLIENT or
table.HasValue({"admin", "superadmin", "modo", "modotest", "chefmodo", "chefadmin", "vip"}, ply:GetNWString("usergroup"))
end,
CustomCheckFailMsg = "Désolez Vous ne pouvez pas accéder a ce job car vous n'êtes pas VIP.",
PlayerDeath = function(ply, weapon, killer)
ply:teamBan()
ply:changeTeam(GAMEMODE.DefaultTeam, true)
if killer:IsPlayer() then
DarkRP.notifyAll(0, 4, "Le Parrain est mort.")
else
DarkRP.notifyAll(0, 4, "Le Parrain est mort.")
end
end
})
TEAM_POLICE = DarkRP.createJob("Policier", {
color = Color(0, 85, 147, 255),
model = {"models/fear/player/portal/male_3.mdl","models/fear/player/portal/male_6.mdl"},
description = [[Le protecteur de chaque citoyen qui vit dans la ville!
Vous avez le pouvoir d'arrêter les criminels et protéger les innocents.
Frapper un joueur avec votre arrestation matraque pour les mettre en prison.
Frappez un joueur avec un stunstick et ils peuvent apprendre à obéir à la loi.
Le Bélier peut briser la porte d'un criminel, d'un mandat d'arrestation.
Le Bélier peut également débloquer des accessoires congelés (si activé).
Type / Wanted <nom> pour alerter le public à la présence d'un criminel]],
weapons = {"weapon_fists", "weapon_arc_atmcard", "stunstick", "m9k_hk45", "weapon_cuff_police", "stungun", "weapon_policebaton", "door_ram", "arrest_stick", "unarrest_stick", "weaponchecker", "idcard", "weapon_eginventory_checker", "itemstore_pickup", "vc_spikestrip_wep", "speed_gun"},
command = "police",
max = 10,
hasRadio = true,
PlayerSpawn = function(ply) ply:SetArmor(100) end,
customCheck = function(ply) return ply:GetUTimeTotalTime() >= 3600 end,
CustomCheckFailMsg = "Vous devez jouer " .. string.NiceTime( 3600 ) .." pour avoir ce metier.",
salary = 100,
admin = 0,
vote = false,
hasLicense = true,
candemote = true,
PlayerDeath = function(ply, weapon, killer)
ply:teamBan()
ply:changeTeam(GAMEMODE.DefaultTeam, true)
if killer:IsPlayer() then
DarkRP.notifyAll(0, 4, "Un Policier est mort.")
else
DarkRP.notifyAll(0, 4, "Un Policier est mort.")
end
end
})
TEAM_CHIEF = DarkRP.createJob("Commissaire de Police", {
color = Color(20, 20, 255, 255),
model = {
"models/portal2/patrol_02.mdl",
"models/portal2/patrol_04.mdl",
"models/portal2/patrol_05.mdl",
"models/portal2/patrol_06.mdl",
"models/portal2/patrol_07.mdl",
"models/portal2/patrol_08.mdl",
"models/portal2/patrol_09.mdl"},
description = [[Le commissaire de police prend les decisions pour les Policiers.
En coordination avec la Police il fait reigner la loi dans la ville.]],
weapons = {"weapon_fists", "weapon_arc_atmcard", "stunstick", "m9k_hk45", "weapon_cuff_police", "stungun", "weapon_policebaton", "door_ram", "arrest_stick", "unarrest_stick", "weaponchecker", "m9k_mp5", "weapon_eginventory_checker", "itemstore_pickup", "vc_spikestrip_wep", "speed_gun"},
command = "chief",
max = 1,
salary = 200,
admin = 0,
vote = true,
hasLicense = true,
hasRadio = true,
PlayerSpawn = function(ply) ply:SetArmor(100) end,
customCheck = function(ply) return ply:GetUTimeTotalTime() >= 86400 end,
CustomCheckFailMsg = "Vous devez jouer " .. string.NiceTime( 86400 ) .." pour avoir ce metier.",
chief = true,
ammo = {
["pistol"] = 100,
["ar2"] = 100,
["buckshot"] = 100,
}
})
TEAM_BAC = DarkRP.createJob("*VIP*BAC", {
color = Color(20, 150, 20, 255),
model = {
"models/player/Group01/Female_01.mdl",
"models/player/Group01/Female_02.mdl",
"models/player/Group01/Female_03.mdl",
"models/player/Group01/Female_04.mdl",
"models/player/Group01/Female_06.mdl",
"models/player/group01/male_01.mdl",
"models/player/Group01/Male_02.mdl",
"models/player/Group01/male_03.mdl",
"models/player/Group01/Male_04.mdl",
"models/player/Group01/Male_05.mdl",
"models/player/Group01/Male_06.mdl",
"models/player/Group01/Male_07.mdl",
"models/player/Group01/Male_08.mdl",
"models/player/Group01/Male_09.mdl",
},
description = [[]],
weapons = {"stungun", "weapon_arc_atmcard", "weapon_fists", "m9k_deagle", "arrest_stick", "unarrest_stick", "weaponchecker", "weapon_cuff_police", "policebadge", "stunstick", "itemstore_pickup"},
command = "bac",
max = 3,
salary = 150,
admin = 0,
customCheck = function(ply) return CLIENT or
table.HasValue({"admin", "superadmin", "modo", "modotest", "chefmodo", "chefadmin", "vip"}, ply:GetNWString("usergroup"))
end,
CustomCheckFailMsg = "Désolez Vous ne pouvez pas accéder a ce job car vous n'êtes pas VIP.",
vote = true,
hasLicense = false,
hasRadio = true,
customCheck = function(ply) return ply:GetUTimeTotalTime() >= 3600 end,
CustomCheckFailMsg = "Vous devez jouer " .. string.NiceTime( 3600 ) .." pour avoir ce metier.",
PlayerDeath = function(ply, weapon, killer)
ply:teamBan()
ply:changeTeam(GAMEMODE.DefaultTeam, true)
if killer:IsPlayer() then
DarkRP.notifyAll(0, 4, "Un Agent de la bac est mort.")
else
DarkRP.notifyAll(0, 4, "Un agent de la bac est mort.")
end
end
})
TEAM_METH = DarkRP.createJob("Producteur de Meth", {
color = Color(239, 234, 99, 255),
model = {"models/player/hostage/hostage_04.mdl"},
description = [[Vous vendez de la Meth .]],
weapons = {"weapon_fists", "weapon_arc_atmcard", "idcard", "itemstore_pickup"},
command = "Meth",
max = 3,
salary = 100,
admin = 0,
vote = false,
hasLicense = false,
candemote = true,
})
TEAM_HOBO = DarkRP.createJob("SDF", {
color = Color(80, 45, 0, 255),
model = {"models/player/corpse1.mdl"},
description = [[Le membre le plus bas de la société. Tout le monde se moque de vous.
Vous ne possedez pas de maison.
Mendier pour votre nourriture et de l'argent
Chantez pour tout le monde qui passe à obtenir de l'argent
Faites votre propre maison en bois, quelque part dans un coin ou à l'exterieur de la porte de quelqu'un d'autre]],
weapons = {"weapon_bugbait", "weapon_fists", "itemstore_pickup"},
command = "hobo",
max = 0,
salary = 0,
admin = 0,
vote = false,
hasLicense = false,
candemote = false,
hobo = true,
})
TEAM_SECRET = DarkRP.createJob("Secretaire du maire", {
color = Color(19, 136, 8),
model = {"models/fearless/mayor2.mdl"},
description = [[]],
weapons = {"weapon_fists", "weapon_arc_atmcard", "weapon_gpee", "itemstore_pickup", "idcard", "itemstore_pickup"},
command = "Secrait",
max = 1,
type = "police",
salary = 250,
admin = 0,
vote = true,
hasLicense = false,
})
TEAM_MOBBOSSS = DarkRP.createJob("Tueur à Gage", {
color = Color(20, 150, 20, 255),
model = {
"models/player/Group01/Female_01.mdl",
"models/player/Group01/Female_02.mdl",
"models/player/Group01/Female_03.mdl",
"models/player/Group01/Female_04.mdl",
"models/player/Group01/Female_06.mdl",
"models/player/group01/male_01.mdl",
"models/player/Group01/Male_02.mdl",
"models/player/Group01/male_03.mdl",
"models/player/Group01/Male_04.mdl",
"models/player/Group01/Male_05.mdl",
"models/player/Group01/Male_06.mdl",
"models/player/Group01/Male_07.mdl",
"models/player/Group01/Male_08.mdl",
"models/player/Group01/Male_09.mdl",
},
description = [[Prenez les contrats de vos clients.]],
weapons = {"weapon_fists", "weapon_arc_atmcard", "idcard", "itemstore_pickup"},
command = "mobboss",
max = 4,
salary = 150,
admin = 0,
vote = false,
hasLicense = false,
candemote = true,
PlayerDeath = function(ply, weapon, killer)
ply:teamBan()
ply:changeTeam(GAMEMODE.DefaultTeam, true)
if killer:IsPlayer() then
DarkRP.notifyAll(0, 4, "Le tueur a gage est mort.")
else
DarkRP.notifyAll(0, 4, "Le tueur a gage est mort.")
end
end
})
TEAM_MOBBOSS = DarkRP.createJob("*VIP* Tueur à Gage Pro", {
color = Color(20, 150, 20, 255),
model = {
"models/player/Group01/Female_01.mdl",
"models/player/Group01/Female_02.mdl",
"models/player/Group01/Female_03.mdl",
"models/player/Group01/Female_04.mdl",
"models/player/Group01/Female_06.mdl",
"models/player/group01/male_01.mdl",
"models/player/Group01/Male_02.mdl",
"models/player/Group01/male_03.mdl",
"models/player/Group01/Male_04.mdl",
"models/player/Group01/Male_05.mdl",
"models/player/Group01/Male_06.mdl",
"models/player/Group01/Male_07.mdl",
"models/player/Group01/Male_08.mdl",
"models/player/Group01/Male_09.mdl",
},
description = [[Prenez les contrats de vos clients.]],
weapons = {"weapon_fists", "weapon_arc_atmcard", "realistic_hook", "m9k_contender", "itemstore_pickup"},
command = "mobbosss",
max = 3,
salary = 200,
admin = 0,
vote = false,
hasLicense = false,
candemote = true,
customCheck = function(ply) return CLIENT or
table.HasValue({"admin", "superadmin", "modo", "modotest", "chefmodo", "chefadmin", "vip"}, ply:GetNWString("usergroup"))
end,
CustomCheckFailMsg = "Désolez Vous ne pouvez pas accéder a ce job car vous n'êtes pas VIP.",
PlayerDeath = function(ply, weapon, killer)
ply:teamBan()
ply:changeTeam(GAMEMODE.DefaultTeam, true)
if killer:IsPlayer() then
DarkRP.notifyAll(0, 4, "Le Tueur a gage est mort.")
else
DarkRP.notifyAll(0, 4, "Le Tueur a gage est mort.")
end
end
})
TEAM_VOLEUR = DarkRP.createJob("Voleur", {
color = Color(20, 150, 20, 255),
model = {
"models/player/Group01/Female_01.mdl",
"models/player/Group01/Female_02.mdl",
"models/player/Group01/Female_03.mdl",
"models/player/Group01/Female_04.mdl",
"models/player/Group01/Female_06.mdl",
"models/player/group01/male_01.mdl",
"models/player/Group01/Male_02.mdl",
"models/player/Group01/male_03.mdl",
"models/player/Group01/Male_04.mdl",
"models/player/Group01/Male_05.mdl",
"models/player/Group01/Male_06.mdl",
"models/player/Group01/Male_07.mdl",
"models/player/Group01/Male_08.mdl",
"models/player/Group01/Male_09.mdl",
},
description = [[Il est le plus bat de la société des voleurs ! Ce qu'il fait, c'est simplement de voler des personnes sans le faire de mal !]],
weapons = {"keypad_crack", "ultimate_disguise_kit", "lockpick", "weapon_fists", "swep_pickpocket", "weapon_arc_atmcard", "idcard", "keypad_cracker", "ultimate_disguise_kit", "itemstore_pickup"},
command = "voleur",
max = 5,
salary = 100,
admin = 0,
vote = false,
hasLicense = false,
candemote = true,
})
TEAM_HACKER = DarkRP.createJob("Hacker", {
color = Color(20, 150, 20, 255),
model = {
"models/player/Group01/Female_01.mdl",
"models/player/Group01/Female_02.mdl",
"models/player/Group01/Female_03.mdl",
"models/player/Group01/Female_04.mdl",
"models/player/Group01/Female_06.mdl",
"models/player/group01/male_01.mdl",
"models/player/Group01/Male_02.mdl",
"models/player/Group01/male_03.mdl",
"models/player/Group01/Male_04.mdl",
"models/player/Group01/Male_05.mdl",
"models/player/Group01/Male_06.mdl",
"models/player/Group01/Male_07.mdl",
"models/player/Group01/Male_08.mdl",
"models/player/Group01/Male_09.mdl",
},
description = [[Il est le plus bat de la société des voleurs ! Ce qu'il fait, c'est simplement de voler des personnes sans le faire de mal !]],
weapons = {"weapon_fists", "weapon_arc_atmcard", "weapon_arc_atmhack", "itemstore_pickup"},
command = "hacker",
max = 2,
salary = 100,
admin = 0,
vote = false,
hasLicense = false,
candemote = true,
})
TEAM_ADMIN = DarkRP.createJob("Staff De RockFordCityRp", {
color = Color(95, 61, 168, 255),
model = {"models/player/anon/anon.mdl"},
description = [[Job pour les admins .]],
weapons = {"stungun", "weapon_fists", "weapon_arc_atmcard", "weapon_keypadchecker", "itemstore_pickup", "vc_wrench", "weaponchecker", "itemstore_checker"},
command = "Staff",
max = 0,
salary = 5,
admin = 0,
vote = false,
hasLicense = false,
candemote = false,
customCheck = function(ply) return CLIENT or
table.HasValue({"modo", "superadmin", "modotest", "chefmodo", "Chef Staff", "admin", "Moderateur", "Moderateur-Test"}, ply:GetNWString("usergroup"))
end,
CustomCheckFailMsg = "vous n'êtes pas un membre du staff.",
})
--[[---------------------------------------------------------------------------
Define which team joining players spawn into and what team you change to if demoted
---------------------------------------------------------------------------]]
GAMEMODE.DefaultTeam = TEAM_CITIZEN
--[[---------------------------------------------------------------------------
Define which teams belong to civil protection
Civil protection can set warrants, make people wanted and do some other police related things
---------------------------------------------------------------------------]]
GAMEMODE.CivilProtection = {
[TEAM_POLICE] = true,
[TEAM_BAC] = true,
[TEAM_MAYOR] = true,
[TEAM_RAID] = true,
[TEAM_CHIEF] = true,
[TEAM_CHEFRAID] = true,
[TEAM_GIGN] = true,
}
--[[---------------------------------------------------------------------------
Jobs that are hitmen (enables the hitman menu)
---------------------------------------------------------------------------]]
DarkRP.addHitmanTeam(TEAM_MOBBOSS)
DarkRP.addHitmanTeam(TEAM_MOBBOSSS)
Dernière édition: