Hello! So, I’m trying to make a door with a proximity promt, and have been super successful so far, (for my first time trying them). However, I can’t figure out how to make it so only a certain group rank can only open the door. I’ve searched all around the developer fourm, and tried youtube, most everything. No one seems to be able to help. Can anyone here help? Here’s my script so far that allows me to open the door, wait for a certain amount of time, then it closes.
In short:
I need help making it so a certain rank or above in a group can only open a door with a proximity promt.
Script: (Yes, way more than it needs to be however its in a way that makes it harder for glitchers.
game.Workspace.Test.ProximityPrompt.Triggered:Connect(function(player)
*** game.Workspace.Door1.Part1.CanCollide = false***
*** game.Workspace.Door1.Part2.CanCollide = false***
*** game.Workspace.Door1.Part3.CanCollide = false***
*** game.Workspace.Door1.Part4.CanCollide = false***
*** game.Workspace.Door1.Part5.CanCollide = false***
*** game.Workspace.Door1.Part6.CanCollide = false***
*** game.Workspace.Door1.Part7.CanCollide = false***
*** game.Workspace.Door1.Part8.CanCollide = false***
*** game.Workspace.Door1.Part9.CanCollide = false***
*** game.Workspace.Door1.Part10.CanCollide = false***
*** game.Workspace.Door1.Part11.CanCollide = false***
*** game.Workspace.Door1.Part12.CanCollide = false***
*** game.Workspace.Door1.Part13.CanCollide = false***
*** game.Workspace.Door1.Part14.CanCollide = false***
*** game.Workspace.Door1.Part15.CanCollide = false***
*** game.Workspace.Door1.Part16.CanCollide = false***
*** game.Workspace.Door1.Part17.CanCollide = false***
*** game.Workspace.Door1.Part18.CanCollide = false***
*** game.Workspace.Door1.Part19.CanCollide = false***
*** game.Workspace.Door1.Part20.CanCollide = false***
*** game.Workspace.Door1.Part21.CanCollide = false***
*** game.Workspace.Door1.Part22.CanCollide = false***
*** game.Workspace.Door1.Part23.CanCollide = false***
*** game.Workspace.Door1.Part24.CanCollide = false***
*** game.Workspace.Door1.Part25.CanCollide = false***
*** game.Workspace.Door1.Part26.CanCollide = false***
*** game.Workspace.Door1.Part27.CanCollide = false***
*** game.Workspace.Door1.Part28.CanCollide = false***
*** game.Workspace.Door1.Part29.CanCollide = false***
*** game.Workkspace.Door1.Part30.CanCollide = false***
*** print(“Opened!”)***
*** wait(20)***
*** game.Workspace.Door1.Part1.CanCollide = true***
*** game.Workspace.Door1.Part2.CanCollide = true***
*** game.Workspace.Door1.Part3.CanCollide = true***
*** game.Workspace.Door1.Part4.CanCollide = true***
*** game.Workspace.Door1.Part5.CanCollide = true***
*** game.Workspace.Door1.Part6.CanCollide = true***
*** game.Workspace.Door1.Part7.CanCollide = true***
*** game.Workspace.Door1.Part8.CanCollide = true***
*** game.Workspace.Door1.Part9.CanCollide = true***
*** game.Workspace.Door1.Part10.CanCollide = true***
*** game.Workspace.Door1.Part11.CanCollide = true***
*** game.Workspace.Door1.Part12.CanCollide = true***
*** game.Workspace.Door1.Part13.CanCollide = true***
*** game.Workspace.Door1.Part14.CanCollide = true***
*** game.Workspace.Door1.Part15.CanCollide = true***
*** game.Workspace.Door1.Part16.CanCollide = true***
*** game.Workspace.Door1.Part17.CanCollide = true***
*** game.Workspace.Door1.Part18.CanCollide = true***
*** game.Workspace.Door1.Part19.CanCollide = true***
*** game.Workspace.Door1.Part20.CanCollide = true***
*** game.Workspace.Door1.Part21.CanCollide = true***
*** game.Workspace.Door1.Part22.CanCollide = true***
*** game.Workspace.Door1.Part23.CanCollide = true***
*** game.Workspace.Door1.Part24.CanCollide = true***
*** game.Workspace.Door1.Part25.CanCollide = true***
*** game.Workspace.Door1.Part26.CanCollide = true***
*** game.Workspace.Door1.Part27.CanCollide = true***
*** game.Workspace.Door1.Part28.CanCollide = true***
*** game.Workspace.Door1.Part29.CanCollide = true***
*** game.Workspace.Door1.Part30.CanCollide = true***
*** print(“Closed.”)***
end)