[B][I]I just bought a code from someone and it has a bug in it. Could someone please help me ?:)[/I][/B]
[B][I]ERROR: [/I][/B][ERROR] lua/entities/neths_car_dealer/cl_init.lua:84: attempt to compare nil with number
1. func - lua/entities/neths_car_dealer/cl_init.lua:84
2. unknown - lua/includes/modules/net.lua:31
[B][I]CL_INIT.LUA (lines 60-100)[/I][/B]
local MainLabel = vgui.Create('DLabel', LogoPanel)
MainLabel:SetFont('DefaultBoldTahoma')
MainLabel:SetText('Car Shop')
MainLabel:SizeToContents()
MainLabel:SetColor(Color( 255, 173, 0, 255 ))
MainLabel:SetPos( 0, 0 )
MainLabel:CenterHorizontal()
local ScrollPanel = vgui.Create( "DScrollPanel", cl_nCD.Menu )
ScrollPanel:SetSize( 390, 520 )
ScrollPanel:SetPos( 5, 75 )
ScrollPanel.Paint = function( self )
draw.RoundedBox( 6, 0, 0, self:GetWide(), self:GetTall(), Color( 255, 173, 0, 255 ) )
draw.RoundedBox( 6, 1, 1, self:GetWide()-2, self:GetTall()-2, Color( 75, 75, 75, 255 ) )
end
local CarList = vgui.Create( "DIconLayout", ScrollPanel )
CarList:SetSize( 375, 515 )
CarList:SetPos( 1, 1 )
CarList:SetSpaceY( 1 )
CarList:SetSpaceX( 0 )
for i, carTbl in pairs (sh_nCD.Cars) do
local CostColor = Color( 255, 173, 0, 255 )
if carTbl.CarPrice > Wallet then
CostColor = Color( 100, 100, 100, 255 )
if sh_nCD.Config.PermamentCars == true then
for k, v in pairs (cl_nCD.PlayerCars) do
if v == i then
CostColor = Color( 255, 173, 0, 255 )
break
end
end
end
end
local CarPanel = vgui.Create('DPanel', CarList)
CarPanel:SetSize( 375, 200 )
CarPanel.Paint = function( self )
draw.RoundedBox( 6, 0, 0, self:GetWide(), self:GetTall(), Color( 35, 35, 35, 255 ) )
end
[B][I]The cars won't show up in the car dealer menu also .[/I][/B]
This code is terribly fucked up, I suggest just to get an addon from someone i bieleve one was just released in the gamemode and addon release sub forum....
[QUOTE=bmatchett;41965537]This code is terribly fucked up, I suggest just to get an addon from someone i bieleve one was just released in the gamemode and addon release sub forum....[/QUOTE]
what am i supposed to be looking for ?:)
There was an addon released a little while ago.. Look for it in the other sub forum LABLLED ADDON AND GAMEMODE RELEASE
[editline]26th August 2013[/editline]
[URL="http://facepunch.com/showthread.php?t=1266627"]Here you go :)[/URL]
[QUOTE=bmatchett;41974783]There was an addon released a little while ago.. Look for it in the other sub forum LABLLED ADDON AND GAMEMODE RELEASE
[editline]26th August 2013[/editline]
[URL="http://facepunch.com/showthread.php?t=1266627"]Here you go :)[/URL][/QUOTE]
Thanks :) but i've payed 13 dollars for this one and it has a nice layout and stuff idk what's wrong with it but i kinda want it fixed :P :)
Then you might want to contact the author to fix his code.
Or you can just take the derma from the car dealer you had before such as the layout and just switch it with this new one... So simple I'll do it for ya for 5 bucks :P
Sorry, you need to Log In to post a reply to this thread.