I wanted to make a wall that'd let only a certain rank go through.
This is what i've tried but idk how to define a group role:
script.Parent.Touched:Connect(function()
if game.Players.LocalPlayer.Name == "UsernameHere" then
script.Parent.CanCollide = false
else
script.Parent.CanCollide = true
end
end)

1 comment
I changed my script. have a look