Dark RP shared.lua issue, please help

I have been working on this DarkRP server now for the last week to get things working just right. Today I was helped with getting the downloads working and now I have run into another problem. Some of the models do not download correctly. So I decided to replace them with working ones such as the monk model and so on. Basically getting rid of the custom ones for default hl2 ones.

So when I am doing this in DarkRP’s shared.lua file no jobs show up anymore. I have a working version of the current file, but in it there are 3 models that do not work. If I replace any of the non working models even with the default hl2 ones, I cannot see the jobs list. In example:

[lua]TEAM_POLICE = AddExtraTeam(“Police Officer”, Color(25, 25, 170, 255), “models/humans/nypd/male_01_player.mdl”,[/lua]

into:

[lua]TEAM_POLICE = AddExtraTeam(“Police Officer”, Color(25, 25, 170, 255), “models/humans/nypd/male_02_player.mdl”,[/lua]

(yes I know those are not the default ones, but the file structure is correct and so on as it currently works, but the model is broken with a missing texture on it. ALSO I know that replacing one with another uncertain one yadda yadda)

my point in the long run is that I will even replace it with the “models/player/gman_high.mdl” and still it shows up with no jobs in the list. I have made sure that there are no extra spaces in the code, no random commas and so on. I just can’t figure out why the list wont load when it allowed me to change them all before setting up fast dl’s.

Is it something to do with not having the files on the fast dl for the shared file? if so where do i put the shared file on the fast dl? Also getting rid of the class is not a possibility since DarkRP has some issues to put it mildly when editing above a certain line.

EDIT:
Just tried using this instead and it failed as well, but if I switch back to using the broken model, then it works just fine…

[lua]TEAM_POLICE = AddExtraTeam(“Police Officer”, Color(25, 25, 170, 255), “models/player/gasmask.mdl”,[/lua]

by the way, I don’t really feel like uninstalling darkrp again and trying to redo everything I just spent a week on. Also, I know there is more to the code, but I am not even touching that portion, the rest is all done I just need to be able to change the model or at least know why it isn’t working so I can find a way around this.

[lua]
/--------------------------------------------------------
Default teams. If you make a team above the citizen team, people will spawn with that team!
--------------------------------------------------------
/
TEAM_CITIZEN = AddExtraTeam(“Citizen”, Color(20, 150, 20, 255), {
“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/Female_07.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”},
[[The Citizen is the most basic level of society you can hold
besides being a hobo.
You have no specific role in city life.]], {}, “citizen”, 0, 25, 0, false, false)

TEAM_POLICE = AddExtraTeam(“Police Officer”, Color(25, 25, 170, 255), “models/humans/nypd/male_01_player.mdl”, [[The protector of every citizen that lives in the city .
You have the power to arrest criminals and protect innocents.
Hit them with your arrest baton to put them in jail
Bash them with a stunstick and they might learn better than to disobey
the law.
The Battering Ram can break down the door of a criminal with a warrant
for his/her arrest.
The Battering Ram can also unfreeze frozen props(if enabled).
Type /wanted <name> to alert the public to this criminal
OR go to tab and warrant someone by clicking the warrant button]], {“arrest_stick”, “unarrest_stick”, “weapon_glock2”, “stunstick”, “door_ram”, “weaponchecker”}, “cp”, 10, 65, 0, true, true)

TEAM_GANG = AddExtraTeam(“Gangster”, Color(75, 75, 75, 255), {
“models/player/Group03/Female_01.mdl”,
“models/player/Group03/Female_02.mdl”,
“models/player/Group03/Female_03.mdl”,
“models/player/Group03/Female_04.mdl”,
“models/player/Group03/Female_06.mdl”,
“models/player/Group03/Female_07.mdl”,
“models/player/group03/male_01.mdl”,
“models/player/Group03/Male_02.mdl”,
“models/player/Group03/male_03.mdl”,
“models/player/Group03/Male_04.mdl”,
“models/player/Group03/Male_05.mdl”,
“models/player/Group03/Male_06.mdl”,
“models/player/Group03/Male_07.mdl”,
“models/player/Group03/Male_08.mdl”,
“models/player/Group03/Male_09.mdl”}, [[The lowest person of crime.
A gangster generally works for the Mobboss who runs the crime family.
The Mobboss sets your agenda and you follow it or you might be punished.]], {}, “gangster”, 5, 40, 0, false, false)

TEAM_MOB = AddExtraTeam(“Mob boss”, Color(25, 25, 25, 255), “models/player/gman_high.mdl”, [[The Mobboss is the boss of the criminals in the city.
With his power he coordinates the gangsters and forms an efficent crime
organization.
He has the ability to break into houses by using a lockpick.
The Mobboss also can unarrest you.]], {“lockpick”, “unarrest_stick”}, “mobboss”, 1, 100, 0, false, false)

TEAM_GUN = AddExtraTeam(“Gun Dealer”, Color(255, 140, 0, 255), “models/player/guerilla.mdl”, [[A gun dealer is the only person who can sell guns to other
people.
However, make sure you aren’t caught selling guns that are illegal to
the public.
/Buyshipment <name> to Buy a weapon shipment
/Buygunlab to Buy a gunlab that spawns P228 pistols]], {}, “gundealer”, 3, 75, 0, false, true)

TEAM_MEDIC = AddExtraTeam(“Medic”, Color(47, 79, 79, 255), “models/player/kleiner.mdl”, [[With your medical knowledge, you heal players to proper
health.
Without a medic, people can not be healed.
Left click with the Medical Kit to heal other players.
Right click with the Medical Kit to heal yourself.]], {“med_kit”}, “medic”, 3, 45, 0, false, false)

TEAM_COOK = AddExtraTeam(“Cook”, Color(238, 99, 99, 255), “models/player/mossman.mdl”, [[As a cook, it is your responsibility to feed the other members
of your city.
You can spawn a microwave and sell the food you make:
/Buymicrowave]], {}, “cook”, 3, 45, 0, 0, false)

TEAM_CHIEF = AddExtraTeam(“Chief of Police”, Color(20, 20, 255, 255), “models/player/dickective_badass.mdl”, [[The Chief is the leader of the police.
Coordinate the police forces to bring law to the city
Hit them with arrest baton to put them in jail
Bash them with a stunstick and they might learn better than to
disobey 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 this criminal
Type /jailpos to set the Jail Position]], {“arrest_stick”, “unarrest_stick”, “weapon_deagle2”, “stunstick”, “door_ram”, “weaponchecker”}, “chief”, 1, 75, 0, false, true, TEAM_POLICE)

TEAM_MAYOR = AddExtraTeam(“Mayor”, Color(150, 20, 20, 255), “models/player/breen.mdl”, [[The Mayor of the city creates laws to serve the greater good
of the people.
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]], {}, “mayor”, 1, 85, 0, true, false/, {TEAM_CHIEF, TEAM_POLICE}/)
/*

HOW TO MAKE AN EXTRA CLASS!!!

You can make extra classes here. Set everything up here and the rest will be done for you! no more editing 100 files without knowing what you’re doing!!!
Ok here’s how:

To make an extra class do this:
AddExtraTeam( “<NAME OF THE CLASS>”, Color(<red>, <Green>, <blue>, 255), “<Player model>” , [[<the description(it can have enters)>]], { “<first extra weapon>”,"<second extra weapon>", etc…}, “<chat command to become it(WITHOUT THE /!)>”, <maximum amount of this team> <the salary he gets>, 0/1/2 = public /admin only / superadmin only, <1/0/true/false Do you have to vote to become it>, true/false DOES THIS TEAM HAVE A GUN LICENSE?, TEAM: Which team you need to be to become this team)

The real example is here: it’s the Hobo: */

–VAR without /!!! The name the color(what you see in tab) the player model The description
TEAM_HOBO = AddExtraTeam(“Hobo”, Color(80, 45, 0, 255), “models/player/group02/male_01.mdl”, [[The lowest member of society. All people see you laugh.
You have no home.
Beg for your food and money
Sing for everyone who passes to get money
Make your own wooden home somewhere in a corner or
outside someone else’s door]], {“weapon_bugbait”}, “hobo”, 5, 0, 0, false)
//No extra weapons say /hobo to become hobo Maximum hobo’s = 5 his salary = 0 because hobo’s don’t earn money. 0 = everyone can become hobo , false = you don’t have to vote to become hobo
// MAKE SURE THAT THERE IS NO / IN THE TEAM NAME OR IN THE TEAM COMMAND:
// TEAM_/DUDE IS WROOOOOONG !!!
// HAVING “/dude” IN THE COMMAND FIELD IS WROOOOOOOONG!!!
//ADD TEAMS UNDER THIS LINE:
TEAM_DRUG = AddExtraTeam(“Drug Dealer”, Color(45, 50, 123, 255), “models/player/group02/male_02.mdl”, [[The member of society that is happy
undermining the economy by selling
illegal narcotics to our kids]], {“weapon_glock2”}, “drugdealer”, 3, 50, 0, false, false)

TEAM_SECURITY = AddExtraTeam(“Security”, Color(155, 78, 200, 255), “models/player/barney.mdl”, [[A readily availible gun for hire to protect
and serve his boss. Security Guards
will watch over places of interest
to the wrong doers]], {“weapon_deagle2”, “stunstick”}, “security”, 5, 50, 0, false, true)

TEAM_DEALER = AddExtraTeam(“Car Dealer”, Color(23, 75, 23, 255), “models/player/group02/male_03.mdl”, [[The car dealer sells and builds cars
for people in the city. If you need
a new car contact one for a good deal]], {“stunstick”}, “cardealer”, 2, 50, 0, false, false)

TEAM_HITMAN = AddExtraTeam(“Hitman”, Color(52, 80, 10, 255), “models/player/phoenix.mdl”, [[The hitman is for hired hits
on people. DO NOT RDM with
this character! If someone does not
pay you, you do not kill people!]], {“weapon_fiveseven2”}, “hitman”, 2, 50, 0, false, false)

TEAM_BUILDER = AddExtraTeam(“Builder”, Color(200, 70, 70, 255), “models/player/group02/male_04.mdl”, [[Builders tend to build things
for others or themselves.]], {“gmod_tool”, “stunstick”}, “builder”, 6, 50, 0, false, false)

TEAM_HVYGUN = AddExtraTeam(“Heavy Gun Dealer”, Color(100, 175, 10, 255), “models/player/leet.mdl”, [[Heavy gun dealers sells different guns
aside of the gun dealer. However
the guns cost alot more. In order to
be a heavy gun dealer you need to first
be a normal gun dealer and earn money.]], {}, “heavygun”, 2, 75, 0, false, true, {TEAM_GUN})

TEAM_JOURNALIST = AddExtraTeam(“Journalist”, Color(35, 35, 35, 255), “models/player/group02/male_05.mdl”, [[Journalists have an easy and hard life.
Their job is to write about the happenings
inside of the city. However to get the good
story you may need to find the action. Use
PC Mod to write news papers, print them, and
sell them to the public]], {}, “journalist”, 2, 40, 0, false, false)

TEAM_BANKER = AddExtraTeam(“Banker”, Color(80, 30, 90, 255), “models/player/group02/male_06.mdl”, [[The banker sets up and secures
people’s money. You get extra money as a banker
so that you can loan and give interest to
those that choose to deposit with you. Use
PC Mod to manage funds for your patrons.]], {}, “banker”, 2, 250, 0, false, false)

TEAM_SHOP = AddExtraTeam(“Shop Keeper”, Color(180, 170, 160, 255), “models/humans/models/player/group02/male_07.mdl”, [[Shop keepers setup stores filled with
unique items in the game and sell them
to players. Bored of civillian life? Try
this class for more income and setup a store.]], {}, “shop”, 10, 50, 0, false, false)

TEAM_THIEF = AddExtraTeam(“Thief”, Color(75, 75, 150, 255), “models/player/group02/male_08.mdl”, [[Thieves are supposed to be slick,
cunning, and fast. Smooth talk someone
or break in when they are gone. You don’t
earn much money, but what you can find from
others you can sell. Watch out for security
and cops, they tend not to like thieves.]], {}, “thief”, 3, 30, 0, false, false)
/*

HOW TO MAKE A DOOR GROUP

AddDoorGroup(“NAME OF THE GROUP HERE, you see this when looking at a door”, Team1, Team2, team3, team4, etc.)

WARNING: THE DOOR GROUPS HAVE TO BE AT THE BOTTOM OF SHARED.LUA. IF THEY ARE NOT, IT MIGHT MUCK UP!

The default door groups, can also be used as examples:
*/
AddDoorGroup(“cops and mayor only”, TEAM_CHIEF, TEAM_POLICE, TEAM_MAYOR)
AddDoorGroup(“gundealer only”, TEAM_GUN, TEAM_HVYGUN)
AddDoorGroup(“banker only”, TEAM_BANKER)
[/lua]

THIS IS THE CODE THAT CURRENTLY WORKS!!! And yet it is the code that is broken. :frowning:

That is the code I have. I know there are a couple mixtakes, but I cannot fix them because every time I try then the game mode breaks and doesn’t show the jobs in the f4 menu. Like, if I fix the problem where it is labeled models/player/models (which is wrong) and change it to where the model actually is, then it won’t work. Which is absolutely retarded. Can anyone help out? I have tried using a stock version of the default shared.lua.

EDIT: Just looked thru console and haven’t found any errors. Confused as hell.

I just tryed those jobs, and everything works just fine here. So I guess that something else is broke.

Any suggestions as what files to look into? I figured there wasn’t anything wrong with the jobs. It is just weird that when I change a model the whole game breaks even if the model is a stock model. I edited the init.lua a while back. I guess I will check in there. Post it up when I get the chance, maybe someone will notice a space or something.

Here is my init file. Aside of this the only other file I have opened up or needed to so far has been the addentities, which work flawlessly. The only thing I did to the init.lua file however was just add 3 lines below the includes to add 3 more includes which I eventually removed because I didn’t need them anymore.

[lua]
GM.Name = “DarkRP 2.4.1”
GM.Author = “By Rickster, Updated: Pcwizdan, Sibre, philxyz, [GNC] Matt, Chrome Bolt, FPtje Falco”

CUR = “$”
GlobalInts = {}
CfgVars = {}

–Overriding garryfunctions to fix the global ints
local oldGetGlobalInt = GetGlobalInt
function GetGlobalInt(id)
if GlobalInts[id] then
if oldGetGlobalInt(id) ~= GlobalInts[id] then
SetGlobalInt(id, GlobalInts[id])
end
return GlobalInts[id]
else
return oldGetGlobalInt(id)
end
end

local OldSetGlobalInt = SetGlobalInt

function SetGlobalInt(id, int)
GlobalInts[id] = int
OldSetGlobalInt(id, int)
for k, ply in pairs(player.GetAll()) do
if v ~= 0 then
umsg.Start(“FRecieveGlobalInt”, ply)
umsg.Long(int)
umsg.String(id)
umsg.End()
else
GlobalInts[k] = nil
end
end
end

function SendGlobalIntsOnSpawn(ply)
for k,v in pairs(GlobalInts) do
if v ~= 0 then
umsg.Start(“FRecieveGlobalInt”, ply)
umsg.Long(v)
umsg.String(k)
umsg.End()
else
GlobalInts[k] = nil
end
end
end
hook.Add(“PlayerInitialSpawn”, “SendGlobalIntsOnSpawn”, SendGlobalIntsOnSpawn)
– end of overriding SetGlobalInt…

–Checking if counterstrike is installed correctly
local foundCSS = false
for k,v in pairs(GetMountedContent()) do
if v == “cstrike” then
foundCSS = true
break
end
end

if not foundCSS then
timer.Create(“TheresNoCSS”, 10, 0, function()
for k,v in pairs(player.GetAll()) do
v:ChatPrint(“Counter:Strike Source is incorrectly installed!”)
v:ChatPrint(“You need it for DarkRP to work!”)
print(“Counter:Strike Source is incorrectly installed!
You need it for DarkRP to work!”)
end
end)
end

– RP Name Overrides

local meta = FindMetaTable(“Player”)
meta.SteamName = meta.Name
meta.Name = function(self)
if CfgVars and CfgVars[“allowrpnames”] == 1 then
self.DarkRPVars = self.DarkRPVars or {}
return self.DarkRPVars.rpname or self:SteamName()
else
return self:SteamName()
end
end
meta.Nick = meta.Name
meta.GetName = meta.Name
– End

RPArrestedPlayers = {}

DeriveGamemode(“sandbox”)
AddCSLuaFile(“language_sh.lua”)
AddCSLuaFile(“MakeThings.lua”)
AddCSLuaFile(“addentities.lua”)
AddCSLuaFile(“cl_init.lua”)
AddCSLuaFile(“shared.lua”)
AddCSLuaFile(“cl_vgui.lua”)
AddCSLuaFile(“entity.lua”)
AddCSLuaFile(“cl_scoreboard.lua”)
AddCSLuaFile(“scoreboard/admin_buttons.lua”)
AddCSLuaFile(“scoreboard/player_frame.lua”)
AddCSLuaFile(“scoreboard/player_infocard.lua”)
AddCSLuaFile(“scoreboard/player_row.lua”)
AddCSLuaFile(“scoreboard/scoreboard.lua”)
AddCSLuaFile(“scoreboard/vote_button.lua”)
AddCSLuaFile(“cl_helpvgui.lua”)
AddCSLuaFile(“showteamtabs.lua”)
AddCSLuaFile(“sh_commands.lua”)
AddCSLuaFile(“DRPDermaSkin.lua”)

– Earthquake Mod addon
resource.AddFile(“sound/earthquake.mp3”)
util.PrecacheSound(“earthquake.mp3”)

DB = {}

– sv_alltalk must be 0
– note, everyone will STILL hear everyone UNLESS rp_voiceradius is 1!!!
– This will fix the rp_voiceradius not working
game.ConsoleCommand("sv_alltalk 0
")

include(“language_sh.lua”)
include(“MakeThings.lua”)
include(“shared.lua”)
include(“help.lua”)
include(“admins.lua”)
include(“data.lua”)
include(“admincc.lua”)
include(“sh_commands.lua”)
include(“chat.lua”)
include(“player.lua”)
include(“sv_gamemode_functions.lua”)
include(“util.lua”)
include(“votes.lua”)
include(“questions.lua”)
include(“entity.lua”)
include(“addentities.lua”)
include(“main.lua”)
include(“bannedprops.lua”)
include(“rating.lua”)

–Falco’s prop protection

AddCSLuaFile(“FPP/sh_CPPI.lua”)
AddCSLuaFile(“FPP/client/FPP_Menu.lua”)
AddCSLuaFile(“FPP/client/FPP_HUD.lua”)
AddCSLuaFile(“FPP/client/FPP_Buddies.lua”)

include(“FPP/sh_CPPI.lua”)
include(“FPP/server/FPP_Settings.lua”)
include(“FPP/server/FPP_Core.lua”)
include(“FPP/server/FPP_Antispam.lua”)

local files = file.Find("…/gamemodes/DarkRP/gamemode/modules/*.lua")
for k, v in pairs(files) do
include(“modules/” … v)
end

function RefreshRPSettings(RESET)
– DO NOT TOUCH THIS! JUST SET THE RP SETTING IN GAME AND IT WILL SAVE AUTOMATICALLY! IF IT DOESNT SAVE AUTOMATICALLY DO rp_savechanges IN CONSOLE!
CfgVars[“ooc”] = 1 --OOC allowed
CfgVars[“allowrpnames”] = 1 --RP Name changing allowed?
CfgVars[“crosshair”] = 1 --Crosshairs enabled?
CfgVars[“strictsuicide”] = 0 --Should players respawn where they suicided (regardless of they’re arrested or not)
CfgVars[“propertytax”] = 0 --Property taxes
CfgVars[“cit_propertytax”] = 0 --Just citizens have to pay property tax?
CfgVars[“banprops”] = 1 --Prop banning
CfgVars[“toolgun”] = 0 --Tool gun enabled?
CfgVars[“allowedprops”] = 0 --Should players be only able to spawn “allowed” props?
CfgVars[“propspawning”] = 1 --Prop spawning enabled?
CfgVars[“adminsents”] = 1 --Should all SENTs be admin only?
CfgVars[“adminsweps”] = 1 --Should all sweps be admin only?
CfgVars[“enforceplayermodel”] = 1 --Should player models be enforced? (Bans using player models like zombie/combine/etc)
CfgVars[“proppaying”] = 0 --Should players pay for props
CfgVars[“letters”] = 1 --Allow letter writing
CfgVars[“enablemayorsetsalary”] = 1 --Allow the Mayor to decide salaries of other players
CfgVars[“chiefjailpos”] = 1 – Can the Chief set the jail positions?
CfgVars[“physgun”] = 1 --Physguns for everybody? 0 = Admins only
CfgVars[“teletojail”] = 1 --Should Criminals Be AUTOMATICALLY Teleported TO jail?
CfgVars[“telefromjail”] = 1 --Should Jailed People be automatically Teleported FROM jail?
CfgVars[“customspawns”] = 1 – Custom spawn points enabled?
CfgVars[“earthquakes”] = 1 – Should earthquakes be enabled?
CfgVars[“dmautokick”] = 1 – Enable deathmatch auto-kick
CfgVars[“doorwarrants”] = 1 – Whether or not CPs require a warrant to smash in a door
CfgVars[“allowvnocollide”] = 0 – Whether or not to allow players to no-collide their vehicles (security)
CfgVars[“restrictbuypistol”] = 0 – Whether /buy is available only to Gun Dealers (if one or more)
CfgVars[“noguns”] = 0 – Whether or not guns are banned on this server
CfgVars[“customjobs”] = 1 – Whether or not players can use the /job command
CfgVars[“deathblack”] = 1 – Whether or not players see black when dead
CfgVars[“norespawn”] = 1 – Whether people have to respawn when they change job or not
CfgVars[“advertisements”] = 1–chatprint advertisements
CfgVars[“copscanunfreeze”] = 1 – Cops can unfreeze props with the battering ram
CfgVars[“copscanunweld”] = 0 – Cops can unweld props with the battering ram
CfgVars[“removeclassitems”] = 1 – Remove(example) every gun shipment when the gundealer changes to a medic or something
CfgVars[“enablebuypistol”] = 1 – People can do /buy
CfgVars[“enableshipments”] = 1 --Enable gun shipments
CfgVars[“lottery”] = 1 – Enable the lottery
CfgVars[“restrictallteams”] = 0
CfgVars[“AdminsSpawnWithCopWeapons”] = 1
CfgVars[“babygod”] = 0
CfgVars[“needwantedforarrest”] = 0
CfgVars[“voiceradius”] = 0
CfgVars[“license”] = 1
CfgVars[“pocket”] = 1
CfgVars[“logging”] = 1
CfgVars[“ironshoot”] = 1
CfgVars[“dropmoneyondeath”] = 0
CfgVars[“allowjobswitch”] = 1
CfgVars[“droppocketdeath”] = 1
CfgVars[“allowvehicleowning”] = 1

-- You can set the exact value of the below items:

CfgVars["aspd"] = 120 -- Arrested speed
CfgVars["rspd"] = 230 -- Run Speed
CfgVars["wspd"] = 155 -- Walk Speed
CfgVars["doorcost"] = 30 -- Cost to buy a door.
CfgVars["vehiclecost"] = 40 -- Car/Airboat Cost
CfgVars["npckillpay"] = 10 -- Amount paid for killing a non-player character
CfgVars["maxnormalsalary"] = 150 -- Maximum Normal Salary
CfgVars["maxmayorsetsalary"] = 120 -- Max salary that a mayor can set for another player
CfgVars["paydelay"] = 160 -- Pay day delay (in seconds)
CfgVars["maxcps"] = 4 -- Max number of CPs you can have
CfgVars["propcost"] = 10 -- Prop cost
CfgVars["maxdruglabs"] = 1 -- Maximum drug labs per player
CfgVars["maxdrugs"] = 2 -- Maximum drug bottles per druglab owner
CfgVars["maxmicrowaves"] = 1 -- Maximum microwave ovens per player
CfgVars["maxfoods"] = 2 -- Maximum food cartons per microwave owner
CfgVars["maxgunlabs"] = 1 -- Maximum gun labs per player
CfgVars["maxmprinters"] = 2 -- Maximum money printers per player
CfgVars["maxletters"] = 4 -- Maximum number of letters per player
CfgVars["quakechance"] = 4000 -- Earthquake probability (1 in 4000)
CfgVars["dmgracetime"] = 30 -- Players have a 30 second grace time by default
CfgVars["dmmaxkills"] = 3 -- ...in which they can make a maximum of 3 kills
CfgVars["demotetime"] = 120 -- Amount of time a player is banned from rejoining a team after being demoted
CfgVars["searchtime"] = 30 -- Amount of time a search warrant is valid for
CfgVars["respawntime"] = 4 -- Amount of time a player has to wait before respawning
CfgVars["wantedtime"] = 120 -- Amount of time a player is wanted for
CfgVars["lotterycommitcost"] = 50
CfgVars["babygodtime"] = 5
CfgVars["pocketitems"] = 10
CfgVars["maxvehicles"] = 5
CfgVars["deathfee"] = 30
CfgVars["startinghealth"] = 100
CfgVars["startingmoney"] = 500
CfgVars["mobagenda"] = ""

if RESET then
	for k,v in pairs(CfgVars) do
		if type(v) == "number" then
			DB.SaveSetting(k, v)
		end
	end
end

for k,v in pairs(CfgVars) do 
	SetGlobalInt(k, v)
end

end
RefreshRPSettings()

local function RPVersion(ply)
local FindGameModes = file.FindDir("…/gamemodes/*")
for _, folder in pairs(FindGameModes) do
local info_txt = file.Read("…/gamemodes/"…folder…"/info.txt")
if not info_txt then info_txt = “” end

	local Gamemode = util.KeyValuesToTable(info_txt)
	if Gamemode.name and string.lower(Gamemode.name) == "darkrp" then 
		local version = Gamemode.version
		local SVN = " non-SVN version"
		
		local entries = file.Read("../gamemodes/"..folder.."/.svn/entries")
		if entries then
			local _, dirFind = string.find(entries, "dir")
			SVN = " revision " .. string.sub(entries, dirFind + 2, dirFind + 4)
		end
		TalkToPerson(ply, Color(0,0,255,255), "This server is running "..folder, Color(1,255, 1), version .. SVN, ply)
		break
	end
end

end
concommand.Add(“rp_version”, RPVersion)

– Vehicle fix from tobba!
function debug.getupvalues(f)
local t, i, k, v = {}, 1, debug.getupvalue(f, 1)
while k do
t[k] = v
i = i+1
k,v = debug.getupvalue(f, i)
end
return t
end

glon.encode_types = debug.getupvalues(glon.Write).encode_types
glon.encode_types[“Vehicle”] = glon.encode_types[“Vehicle”] or {10, function(o)
return (ValidEntity(o) and o:EntIndex() or -1)…"\1"
end}
[/lua]

EDIT: Also, remember, I am not having a problem with the game working. I am having a problem when I edit JUST the models. When I change them over to the working models, (and yes I know they work) it just gets borked and the f4 job menu gets screwed.

I found a way around the issue I am having. Since I cannot change the path for the models, I changed the models to match the path. This only works for me since my jobs are complete, at least for now.

In order to get the models to work, I needed to change the directories to match, change the model names, and the resource file information so that they would download to the new paths needed. I needed to rename a few of them to improper names so that way I could actually see them. Anyways, quick fix for those who have a working shared.lua for darkrp and just need to fix the models.

So everything is fine now?

I hope so :stuck_out_tongue:

No, the shared.lua file is still borked to all hell. However I just bypassed the shared.lua by changing my models around to match up with it. So in other words, the server now functions right, but the shared.lua is still broken.

hey, i just want to ask you guys if i want to set the citizen job with different.


like:
(i got it like this)

TEAM_CITIZEN = AddExtraTeam(“Citizen”, Color(20, 150, 20, 255), “models/player/group01/male_01.mdl”, [[The Citizen is the most basic level of society you can hold
besides being a hobo.
You have no specific role in city life.]], {}, “citizen”, 0, 45, 0, false, false)


I want it so the players can change the models while they are Citzens…
or just so it will be randomly for them…


I’m not sure if its like this:

TEAM_CITIZEN = AddExtraTeam(“Citizen”, Color(20, 150, 20, 255), “set model in here”, “set model in here”, “set model in here” [[The Citizen is the most basic level of society you can hold
besides being a hobo.
You have no specific role in city life.]], {}, “citizen”, 0, 45, 0, false, false)

I never tryed that. But I realy don’t think that it is possible to make them able to change model while citizen. Maybe you could ask an lua coder.