Test For My Server

Could someone make me an example of a derma test that people would have to complete when they join my server and if they complete it correctly, they don’t have to complete it again EVEN AFTER THE SERVER RESTARTS and if they fail (get below a 70%), they get kicked from the server? Thanks in advance!

I’ll have a crack tonight. It shouldn’t be hard.

And do you mean kinda like TacoScript?

This kind what you want? (obviously an actual test required, but the general idea)

On the client…
[lua]local function TestMenu()

local frame = vgui.Create(“DFrame”)
frame:SetSize(500,500)
frame:Center()
frame:MakePopup()
frame:ShowCloseButton(false)

local btn = vgui.Create(“DButton”,frame)
btn:SetSize(100,25)
btn:SetPos(frame:GetWide()/2-btn:GetWide()/2,frame:GetTall/2-btn:GetWide()/2)
btn:SetText(“You passed the test!”)
btn.DoClick = function()
frame:Close()
datastream.StreamToServer(“TestPass”,true,function() LocalPlayer():ChatPrint(“You passed the test!”) end)
end

end

datastream.Hook(“HasPassed”,function(ply,handler,id,encoded,decoded)
if decoded = false then TestMenu() end
end)[/lua]

On the server…
[lua]sql.Query(“CREATE TABLE IF NOT EXISTS testers(‘steam’ TEXT NOT NULL, PRIMARY KEY(‘steam’));”)
datastream.Hook(“TestPass”,function(ply,handler,id,encoded,decoded)
if decoded == true then sql.Query(“INSERT INTO testers VALUES(”…sql.SqlStr(ply:SteamID())…");")
else ply:Kick() end
end)

for _,v in ipairs(player.GetAll()) do
local pass = false
if tonumber(sql.QueryValue("SELECT COUNT(*) FROM testers WHERE steam = " … sql.SQLStr(v:SteamID()) … “;”)) > 0 then
datastream.StreamToClients(v,“HasPassed”,true)
else datastream.StreamToClients(v,“HasPassed”,false) end
end[/lua]

The test from tacoscript?