[CODE]TEAM_MAYOR = DarkRP.createJob("Mayor", {
color = Color(150, 20, 20, 255),
model = "models/player/breen.mdl",
description = [[The Mayor of the city creates laws to govern the city.
If you are the mayor you may create and accept warrants.
Type /wanted <name> to warrant a player.
Type /jailpos to set the Jail Position.
Type /lockdown initiate a lockdown of the city.
Everyone must be inside during a lockdown.
The cops patrol the area.
/unlockdown to end a lockdown]],
weapons = {"unarrest_stick", "stunstick", "weaponchecker"},
command = "mayor",
max = 1,
salary = 55,
admin = 0,
vote = true,
hasLicense = false,
mayor = true,
PlayerDeath = function(ply)
if ply:Team() == TEAM_MAYOR then
ply:changeTeam( TEAM_CITIZEN, true )
for k,v in pairs( player.GetAll() ) do
DarkRP.notify(v, 1, 4, "The Mayor has been killed!")
end
end
end,
})
TEAM_SECRETSERVICE = DarkRP.createJob("Secret Service", {
color = Color(0, 0, 255, 255),
model = "models/player/barney.mdl",
description = [[Protect the president with your life! If he dies so do you!]],
weapons = {"arrest_stick", "unarrest_stick", "stunstick", "door_ram", "weaponchecker", "m9k_hk45", "m9k_g36"},
command = "secretservice",
max = 2,
salary = 50,
admin = 0,
vote = true,
hasLicense = true,
customCheck = function(ply) return ply:CheckGroup( "vip+", "mod", "admin", "superadmin", "headadmin", "senioradmin", "owner") end,
CustomCheckFailMsg = "This job is vip only!",
})
TEAM_POLICE = DarkRP.createJob("Police Officer", {
color = Color(0, 0, 255, 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 <name> to alert the public to the presence of a criminal.]],
weapons = {"arrest_stick", "unarrest_stick", "m9k_hk45", "stunstick", "door_ram", "weaponchecker"},
command = "police",
max = 4,
salary = 45,
admin = 0,
vote = true,
hasLicense = true,
help = {
"Don't abuse your job",
"When you arrest someone they are auto transported to jail.",
"They are auto let out of jail after some time",
"Type /warrant [Nick|SteamID|Status ID] to set a search warrant for a player.",
"Type /wanted [Nick|SteamID|Status ID] to alert everyone to a wanted suspect",
"Type /unwanted [Nick|SteamID|Status ID] to clear the suspect",
"Type /jailpos to set the jail position"
},
})
TEAM_CHIEF = DarkRP.createJob("Police Chief", {
color = Color(0, 0, 255, 255),
model = "models/player/combine_soldier_prisonguard.mdl",
description = [[The Chief is the leader of the DownTown Police Department.
Coordinate the police force to enforce law in the city.
Hit a player with 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 his/her arrest.
Type /wanted <name> to alert the public to the presence of a criminal.
Type /jailpos to set the Jail Position]],
weapons = {"arrest_stick", "unarrest_stick", "m9k_hk45", "stunstick", "door_ram", "weaponchecker", "m9k_m14sp"},
command = "chief",
max = 1,
salary = 50,
admin = 0,
vote = true,
hasLicense = true,
chief = true,
NeedToChangeFrom = TEAM_POLICE,
help = {
"Please don't abuse your job",
"When you arrest someone they are auto transported to jail.",
"They are auto let out of jail after some time",
"Type /warrant [Nick|SteamID|Status ID] to set a search warrant for a player.",
"Type /wanted [Nick|SteamID|Status ID] to alert everyone to a wanted suspect",
"Type /unwanted [Nick|SteamID|Status ID] to clear the suspect"
},
})
TEAM_SWAT = DarkRP.createJob("S.W.A.T", {
color = Color(0, 0, 255, 255),
model = "models/player/urban.mdl",
description = [[You are the city's deadliest tactical division,
use your elit skills to handle the problems regular police cannot]],
weapons = {"arrest_stick", "unarrest_stick", "stunstick", "door_ram", "weaponchecker", "m9k_hk45", "m9k_m4a1"},
command = "swat",
max = 3,
salary = 45,
admin = 0,
vote = true,
hasLicense = true,
customCheck = function(ply) return ply:CheckGroup( "vip+", "mod", "admin", "superadmin", "headadmin", "senioradmin", "owner") end,
CustomCheckFailMsg = "This job is vip only!",
})
TEAM_SWATS = DarkRP.createJob("S.W.A.T Sniper", {
color = Color(0, 0, 255, 255),
model = "models/player/urban.mdl",
description = [[You are the city's deadliest tactical division,
use your elit skills to handle the problems regular police cannot]],
weapons = {"arrest_stick", "unarrest_stick", "stunstick", "door_ram", "weaponchecker", "m9k_hk45", "m9k_aw50"},
command = "swats",
max = 2,
salary = 45,
admin = 0,
vote = true,
hasLicense = true,
customCheck = function(ply) return ply:CheckGroup( "vip+", "mod", "admin", "superadmin", "headadmin", "senioradmin", "owner") end,
CustomCheckFailMsg = "This job is vip only!",
})
TEAM_GUN = DarkRP.createJob("Gun Dealer", {
color = Color(255, 140, 0, 255),
model = "models/player/monk.mdl",
description = [[Gun and Blackmarket Dealers are the only people who can sell guns to other people.
To sell guns you need to make a gun shop.]],
weapons = {},
command = "gundealer",
max = 2,
salary = 45,
admin = 0,
vote = false,
hasLicense = false,
})
TEAM_BMD = DarkRP.createJob("BlackMarket Dealer", {
color = Color(255, 140, 0, 100),
model = "models/player/leet.mdl",
description = [[Gun and Blackmarket Dealers are the only people who can sell guns to other people.
Make sure you aren't caught selling illegal weapons or items to the public!
You might get arrested!]],
weapons = {},
command = "blackmarketdealer",
max = 1,
salary = 25,
admin = 0,
vote = false,
hasLicense = false,
customCheck = function(ply) return ply:CheckGroup( "vip+", "mod", "admin", "superadmin", "headadmin", "senioradmin", "owner") end,
CustomCheckFailMsg = "This job is vip only!",
})
TEAM_GUARD = DarkRP.createJob("Guard", {
color = Color(153, 204, 255, 255),
model = "models/player/odessa.mdl",
description = [[Protect people for money.
Announce who you are protecting in chat with /advert.]],
weapons = {"stunstick"},
command = "bodyguard",
max = 4,
salary = 45,
admin = 0,
vote = false,
hasLicense = false,
})
TEAM_MEDIC = DarkRP.createJob("Medic", {
color = Color(47, 79, 79, 255),
model = "models/player/kleiner.mdl",
description = [[With your medical knowledge you work to restore players to full health.
Without a medic, people cannot be healed.
Left click with the Medical Kit to heal other players.
Right click with the Medical Kit to heal yourself.]],
weapons = {"med_kit"},
command = "medic",
max = 3,
salary = 45,
admin = 0,
vote = false,
hasLicense = false,
medic = true,
})
TEAM_MOBBOSS = DarkRP.createJob("Mob Boss", {
color = Color(25, 25, 25, 255),
model = "models/player/gman_high.mdl",
description = [[The Mob boss is the boss of the criminals in the city.
With his power he coordinates the gangsters and forms an efficient crime organization.
He has the ability to break into houses by using a lockpick.
The Mob boss posesses the ability to unarrest his gang.]],
weapons = {"lockpick", "unarrest_stick"},
command = "mobboss",
max = 1,
salary = 55,
admin = 0,
vote = false,
hasLicense = false,
PlayerDeath = function(ply)
if ply:Team() == TEAM_MOBBOSS then
ply:changeTeam( TEAM_CITIZEN, true )
for k,v in pairs( player.GetAll() ) do
DarkRP.notify(v, 1, 4, "The Mob Boss is dead!")
end
end
end,
})
TEAM_HACK = AddExtraTeam("Hacktivist", {
color = Color(0, 0, 51, 255),
model = "models/pla
I'm not reading all of that, but just make sure commas/brackets/curly brackets are where they're supposed to be and not where they aren't
Check console for script errors, too
it keeps getting a sv_money in darkrp error but thats after they turn into the black model [CODE][ERROR] gamemodes/darkrp/gamemode/modules/money/sv_money.lua:7: attempt to perform arithmetic on a nil value
1. addMoney - gamemodes/darkrp/gamemode/modules/money/sv_money.lua:7
2. callback - gamemodes/darkrp/gamemode/modules/money/sv_money.lua:33
3. retrieveSalary - gamemodes/darkrp/gamemode/modules/base/sv_data.lua:278
4. payDay - gamemodes/darkrp/gamemode/modules/money/sv_money.lua:25
5. unknown - gamemodes/darkrp/gamemode/modules/jobs/sv_jobs.lua:157[/CODE] the error
[QUOTE=TrippleT;46506447]it keeps getting a sv_money in darkrp error but thats after they turn into the black model [CODE][ERROR] gamemodes/darkrp/gamemode/modules/money/sv_money.lua:7: attempt to perform arithmetic on a nil value
1. addMoney - gamemodes/darkrp/gamemode/modules/money/sv_money.lua:7
2. callback - gamemodes/darkrp/gamemode/modules/money/sv_money.lua:33
3. retrieveSalary - gamemodes/darkrp/gamemode/modules/base/sv_data.lua:278
4. payDay - gamemodes/darkrp/gamemode/modules/money/sv_money.lua:25
5. unknown - gamemodes/darkrp/gamemode/modules/jobs/sv_jobs.lua:157[/CODE] the error[/QUOTE]
Then post that code here :v:
Now I'm no rocket scientist but you really fucked up here m9
[code]
TEAM_CRIMEBOSS = AddExtraTeam("Crime Boss", {
color = Color(102, 51, 0, 255),
model = "models/code_gs/50cent/50centplayer.mdl",
description = [[The head of all crime organization, also a drug seller.]],
weapons = {"ninjalockpick", "unarrest_stick", "med_kit"},
command = "crimebossasdfghjkla",
max = 1,
salary = 1000,0000,
admin = 0,
vote = false,
hasLicense = true,
customCheck = function(ply) return ply:SteamID() == "STEAM_0:1:32148240" or ply:SteamID() == "STEAM_0:0:80261755" end,
CustomCheckFailMsg = "This job is cyber's Custom Job!",
})
[/code]
[B]salary = 1000,0000,
salary = 1000,0000,
salary = 1000,0000,
salary = 1000,0000,
salary = 1000,0000,
salary = 1000,0000,
salary = 1000,0000,
salary = 1000,0000,
salary = 1000,0000, [/B]
[I]what were you thinking?[/I]
also, why AddExtraTeam when the rest are DarkRP.createJob ?
[QUOTE=Arizard;46510701]also, why AddExtraTeam when the rest are DarkRP.createJob ?[/QUOTE]
im not sure the person who was making the jobs is crazy. ill try changing that
[editline]17th November 2014[/editline]
[QUOTE=Zedd;46510630]Now I'm no rocket scientist but you really fucked up here m9
[code]
TEAM_CRIMEBOSS = AddExtraTeam("Crime Boss", {
color = Color(102, 51, 0, 255),
model = "models/code_gs/50cent/50centplayer.mdl",
description = [[The head of all crime organization, also a drug seller.]],
weapons = {"ninjalockpick", "unarrest_stick", "med_kit"},
command = "crimebossasdfghjkla",
max = 1,
salary = 1000,0000,
admin = 0,
vote = false,
hasLicense = true,
customCheck = function(ply) return ply:SteamID() == "STEAM_0:1:32148240" or ply:SteamID() == "STEAM_0:0:80261755" end,
CustomCheckFailMsg = "This job is cyber's Custom Job!",
})
[/code]
[B]salary = 1000,0000,
salary = 1000,0000,
salary = 1000,0000,
salary = 1000,0000,
salary = 1000,0000,
salary = 1000,0000,
salary = 1000,0000,
salary = 1000,0000,
salary = 1000,0000, [/B]
[I]what were you thinking?[/I][/QUOTE]
its the owners job i think he did that when i was not looking lol
[editline]17th November 2014[/editline]
[QUOTE=LUModder;46510101]Then post that code here :v:[/QUOTE]
its a new install of darkrp the code has not been changed.
[code]salary = 1000,0000,[/code]
is enough to make your job file throw an error and none of the jobs will work. Is it fixed?
and I'm assuming your error was from not being able to read the salary for 1 job, because it was fucked up.
[QUOTE=Zedd;46513298][code]salary = 1000,0000,[/code]
is enough to make your job file throw an error and none of the jobs will work. Is it fixed?
and I'm assuming your error was from not being able to read the salary for 1 job, because it was fucked up.[/QUOTE]
no the error was caused way before that
[QUOTE=Zedd;46513298][code]salary = 1000,0000,[/code]
is enough to make your job file throw an error and none of the jobs will work. Is it fixed?
and I'm assuming your error was from not being able to read the salary for 1 job, because it was fucked up.[/QUOTE]
no the error was caused way before that, now only one player out of 40 per day has the error of spawning with black model. do you think it could be his client info
[QUOTE=TrippleT;46514472]no the error was caused way before that, now only one player out of 40 per day has the error of spawning with black model. do you think it could be his client info[/QUOTE]
You have 2 commas, it's causing it to error without an error :v
after i deleted that job this one guy is still spawning as the black model and no money
[QUOTE=TrippleT;46514472]no the error was caused way before that, now only one player out of 40 per day has the error of spawning with black model. do you think it could be his client info[/QUOTE]
Yes, but considering that is not even a valid number, it will still give an error.
[code]
model =
[/code]
If you're using more than 1 model in a job, please use a table like:
[code]
model = {"models/player/police.mdl","models/player/police_fem.mdl"},
[/code]
:rolleyes:
Sorry, you need to Log In to post a reply to this thread.