So I need helped so I currently making a Gate I want to make sure it can be locked so they can just click on it and then it opens for that team?
I am currently trying to find out how do i solve this problem i never script but if Myself can get help i would love it!
local Players = game:GetService("Players")
local Teams = game:GetService("Teams")
script.Parent.MouseClick:Connect(function(clicker)
for _, v in pairs(Players:GetChildren()) do
if v == clicker then
if v.Team == Teams["team name"] then
-- open script
end
end
end)