cl_init.lua

Posts 115 of 15 · Page 1 of 1
cl_init.lua
Alright so I started a gamemode recently that im using to practice lua as im learning it but for some reason when i try to test it, it gives me a error in console and says unable to locate garrysmod/gamemodes/copsandrobbers/cl_init.lua i checked to make sure it was in there and it was in there can someone hallp D:
If you cant solve this.

The fuck you making gamemodes for.
Quote Originally Posted by Mundu View Post
If you cant solve this.

The fuck you making gamemodes for.
Did you not see where i said im learning you dumb fuck open your Canadian eyes
Quote Originally Posted by Mundu View Post
If you cant solve this.

The fuck you making gamemodes for.
Everyone has to start somewhere.
Quote Originally Posted by Mundu View Post
If you cant solve this.

The fuck you making gamemodes for.
jesus christ retard what are you doing
I would've helped you but seeing as you took the ignorance of another member so seriously, you should probably learn Lua...and be less of a dick...
Quote Originally Posted by YouDontKnowMeLikeReally View Post
I would've helped you but seeing as you took the ignorance of another member so seriously, you should probably learn Lua...and be less of a dick...
wait so how was i wrong by defending my self and maybe you didnt see either but it says learning and im not being a dick..
Quote Originally Posted by UrxHaxor View Post
Alright so I started a gamemode recently that im using to practice lua as im learning it but for some reason when i try to test it, it gives me a error in console and says unable to locate garrysmod/gamemodes/copsandrobbers/cl_init.lua i checked to make sure it was in there and it was in there can someone hallp D:
Is the file blank?
Quote Originally Posted by MeepDarknessMeep View Post
Is the file blank?
nope its filled with this

 
Code
include( 'shared.lua' )



//Tables
Cake = {}
Cake{1} = "Cops"
Cake{2} = "Robbers"
Cake{3} = "Citizen"

for i=1, 3 do
Msg("Variable 'i' is equal to"..1..".Which Puts You On Team"..Cake[1].."\n")
end

//Zhe HOUD!

function HUDHide( myhud )
for k, v in pairs{"CHudHealth","CHudBattery"} do
if myhud == v then return false end
end
end
hook.Add("HUDShouldDraw","HUDHide",HUDHide)

function GM:HUDPaint()
self.BaseClass:HUDPaint()]
local ply = LocalPlayer()
local HP = LocalPlayer():Health()
local ARM = LocalPlayer():Armor()


surface.CreateFont("ScoreboardText", 43, 300, false, false, "MyFont")
surface.SetTextColor( 0, 150, 50, 255)
surface.SetTextPos( 100, 20)
surface.SetFont( "MyFont")
surface.DrawText( HP )
function
surface.SetTextColor(0 , 150, 50 ,255)
surface.SetTextPos( 100, 30)
surface.SetFont( "MyFont")
surface.DrawText( ARM )
end
end



//The Welcome Message!
function WMsg()
chat.AddText(Color(0, 140, 130), "[CAR] ", Color(255, 255, 255), "Welcome to Cops and Robbers. Made By Nipplepumper!")
end
usermessage.Hook("Welcome", WMsg )
Its been over a year since I've worked with a game mode so I might be wrong but I don't think cl_init.lua is loaded by default. Try putting AddCSLuaFile("cl_init.lua") in your init.lua

Post back if that helps at all.
Quote Originally Posted by Atheon View Post
Its been over a year since I've worked with a game mode so I might be wrong but I don't think cl_init.lua is loaded by default. Try putting AddCSLuaFile("cl_init.lua") in your init.lua

Post back if that helps at all.
I already have that in there :/
Quote Originally Posted by UrxHaxor View Post
I already have that in there :/
Are you including cl_init.lua? Also, you're still looping over the same thing.
Quote Originally Posted by NotDaz View Post
Are you including cl_init.lua? Also, you're still looping over the same thing.
What do you mean
Code:
//Tables
Cake = {}
Cake{1} = "Cops"
Cake{2} = "Robbers"
Cake{3} = "Citizen"

for i=1, 3 do
Msg("Variable 'i' is equal to"..1..".Which Puts You On Team"..Cake[1].."\n")
end
You loop through the first three of cake, but that's pointless because it will send you three messages
Quote Originally Posted by LordOfGears2 View Post
Code:
//Tables
Cake = {}
Cake{1} = "Cops"
Cake{2} = "Robbers"
Cake{3} = "Citizen"

for i=1, 3 do
Msg("Variable 'i' is equal to"..1..".Which Puts You On Team"..Cake[1].."\n")
end
You loop through the first three of cake, but that's pointless because it will send you three messages
Ohhhhhhhhhhhhh
Posts 115 of 15 · Page 1 of 1
This thread is closed for replies.

Similar Threads

Tags for this Thread

None

Need help?