Hello, I am VERY NEW to scripting, so please dumb things down and please do not shame me;
This code will, for some reason, not work.
The purpose of the script; It disables a proximity prompt in a door if the players Access value does not equal anything inside the table.
Code (Localscript):
local player = game.Players.LocalPlayer
local allowed = {"L5"}
local Access = player.Access.Value
for i,v in pairs(Access) do
if v == allowed[1] then
script.Parent.ProximityPrompt.Enabled = true
else
script.Parent.ProximityPrompt.Enabled = false
end
end

3 comments
A good way to troubleshoot is to use print("what should happen")
It did not print anything, even if I put the print at the beginning of the script. What could be happening?
if it is not printing anything then the table isn't working right. or maybe you need to run it from the server. if you change Access to a part instead of that value I bet it would work.