Law Board Error

Hey there I’m running darkrp 2.5 haven’t tested the /placelaws until now when I type that in the billboard spawn but doesn’t let me add laws and I get this error

[lua]
[ERROR] gamemodes/darkrp/entities/entities/darkrp_laws/cl_init.lua:21: attemp
o call field ‘DrawNonParsedSimpleText’ (a nil value)

  1. unknown - gamemodes/darkrp/entities/entities/darkrp_laws/cl_init.lua:21
    [/lua]

I copied and pasted the git hub file to see if that would work but it didnt do anything

Here is my cl_init.lua

[lua]
include(“shared.lua”)

local Laws = {}

function ENT:Draw()
self:DrawModel()

local DrawPos = self:LocalToWorld(Vector(1, -111, 58))

local DrawAngles = self:GetAngles()
DrawAngles:RotateAroundAxis(self:GetAngles():Forward(), 90)
DrawAngles:RotateAroundAxis(self:GetAngles():Up(), 90)

cam.Start3D2D(DrawPos, DrawAngles, 0.4)

	surface.SetDrawColor(0, 0, 0, 255)
	surface.DrawRect(0, 0, 558, 290)

	draw.RoundedBox(4, 0, 0, 558, 30, Color(0, 0, 70, 200))

	draw.DrawNonParsedSimpleText(DarkRP.getPhrase("laws_of_the_land"), "TargetID", 279, 5, Color(255, 0, 0, 255), TEXT_ALIGN_CENTER)

	local col = Color(255, 255, 255, 255)
	local lastHeight = 0
	for k,v in ipairs(Laws) do
		draw.DrawNonParsedText(string.format("%u. %s", k, v), "TargetID", 5, 35 + lastHeight, col)
		lastHeight = lastHeight + ((fn.ReverseArgs(string.gsub(v, "

", “”)))+1)*21
end

cam.End3D2D()

end

local function addLaw(inLaw)
local law = DarkRP.textWrap(inLaw, “TargetID”, 522)

Laws[#Laws + 1] = law

end

local function umAddLaw(um)
local law = um:ReadString()
timer.Simple(0, fn.Curry(addLaw, 2)(law))
hook.Run(“addLaw”, #Laws + 1, law)
end
usermessage.Hook(“DRP_AddLaw”, umAddLaw)

local function umRemoveLaw(um)
local i = um:ReadShort()

hook.Run("removeLaw", i, Laws*)

while i < #Laws do
	Laws* = Laws[i + 1]
	i = i + 1
end
Laws* = nil

end
usermessage.Hook(“DRP_RemoveLaw”, umRemoveLaw)

local function umResetLaws(um)
Laws = {}
fn.Foldl(function(val,v) addLaw(v) end, nil, GAMEMODE.Config.DefaultLaws)
hook.Run(“resetLaws”)
end
usermessage.Hook(“DRP_ResetLaws”, umResetLaws)

function DarkRP.getLaws()
return Laws
end

timer.Simple(0, function()
fn.Foldl(function(val,v) addLaw(v) end, nil, GAMEMODE.Config.DefaultLaws)
end)
[/lua]

Does anyone know why this doesn’t work? any help would be great

What is DrawNonParsedSimpleText defined as? If this is happening with default DarkRP, you should probably make a GitHub issue about it.

Here 'ya go.

Thanks so much for that post for some reason I didnt have that file from the git hub i added it and it worked thanks so much!