local list={
"STEAM_0:0:0",
}
local enable = CreateConVar("steamidkick_enable", "0", {FCVAR_REPLICATED, FCVAR_ARCHIVE})
local function CheckAllowed(ply)
if enable:GetInt()==1 then
local deny=true
local id=ply:SteamID()
for _, entr in pairs(list) do
if id==entr then
deny=false
break
end
end
if deny then
ply:Kick("You're not on the whitelist, ask an admin of GMod.de.")
MsgN("Player "..ply:Nick().." ("..id..") was kicked (not on whitelist)")
else
ply:ChatPrint("Welcome to the GMod.de server!")
end
end
end
hook.Add("PlayerInitialSpawn", "SteamIDCheck", CheckAllowed)