Hide LUA Errors?

Hey, I’ve been using some of the Stargate Weapons to stage battles in GMOD… but, although they work perfectly, there are LUA errors coming up on screen. Go figure, but it’s a pain in the ass. How can I hide these damn things, and all LUA errors?


CreateConVar("lua_showerrors", 1)

hook.Add("LuaError", "LE", function(err) --Return anything other than nil to stop the standard error display
	if (GetConVar("lua_showerrors"):GetInt() == 0) then
		return false
	elseif (GetConVar("lua_showerrors"):GetInt() == 1) then
		return false
end )

I found this code somewhere
I don’t know who made it but it’s somewhere on facepunch

wait, it’s gone on facepunch, but I found his code page.

All credits to the maker, I think his name is Christop


I really should fix the errors now… :confused:

I was going to post “It’s meant to be shown so the developer will be forced to fix it” until I read Stargate, ughhh - Ultra Zing.