Unknown command

Hey i need help with this command…


//Server side

concommand.Add( "Panel", PointSystemPanel )


hook.Add("PlayerSay", "Panel", function(ply, text)
	if text == "!ola" then
		ply:ConCommand("Panel")
	end
end)


// Client side

concommand.Add( "Panel", PointSystemPanel )


Sometimes it opens the panel for me, but most of time it says unknown command “Panel” , maybe this is because i dont really know where to put it in lua…
I have cl_init in autorun/client and init.lua in autorun/server.

You’re overwriting the concommands I would assume. Don’t have the concommand.Add serverside.

I still get the same reaction …Unknown Command “Panel”

use this for clienside:



function PointSystemPanel(ply,bind)
 if (string.find(bind,"Panel")) then
  -- Your code of function here
 end
end
hook.Add("PlayerBindPress","Panel",PointSystemPanel)


And yeah, try to rename init.lua to something else.