Stafflock script does not work

I have made a stafflock script, and it does nothing. Here is the script:
local stafflockon = true
local admin = (
[
[“Vehicleman76”] = true;
)

game:GetService(“Players”).PlayerAdded:Connect(function(player)
if stafflockon == true then
if not player.Name == “bandybead” or player.Name == “bostonn1” or “YourBloxDevJr” or “zackkisfunJr” or “BellaIsabellaz” or “asruiltime” or “Vehicleman76” or “drphilipsen” or “rey_key” or “bird2198” or “redhoou1” or “TacticalFighterX5” or “frogman41231” or “LucaJr1234” then
player.Kick (“you no allow bruh”)
end
else
print (“Access Granted.”)
end

player.Chatted:conneect(function(msg)
	if staffs(player.Name) then
		if msg == "/stafflock on" then
			warn("Stafflock is on!")
			stafflockon = true
		end
		if msg == "/stafflock off" then
			stafflockoff = false
			warn("Stafflock is off!")
		end
	end
	
end)

end)

1 Like

() is used for stuff like function calls and function foo()

But tables and arrays use {} and [],
so to refrence something in a table you either use bar[user.Name] or table.find(bar,user.Name)
and to create a table in a script you use

local bar = {}

Alright, thanks a lot! Super helpful!