I wrote a doorbell script that opens a door when a certain person clicks it, but plays a sound otherwise. However, when anybody clicks it, the door just opens. Here is the script.
function doorbell(hit)
local owner = hit.Parent.Name
if owner == "Wizardel" or "Player" then
script.Parent.Parent.RRD.Sound:Play()
for i = 1, 60 do
script.Parent.Parent.RRD.CFrame = script.Parent.Parent.RRD.CFrame*CFrame.new(0.2, 0, 0)
wait()
end
wait(0.5)
for i = 1, 60 do
script.Parent.Parent.RRD.Sound:Play()
script.Parent.Parent.RRD.CFrame = script.Parent.Parent.RRD.CFrame*CFrame.new(-0.2, 0, 0)
end
else
script.Parent.Sound:play()
end
end
script.Parent.ClickDetector.MouseClick:connect(doorbell)
Please help.

2 comments
I did this, but now nobody can open the doors -_-
Did you try to debug at all? Did you
print(owner)to see what it thinks the names are? Are they exactly how you spelled them? The testing player is usuallyPlayer1, notPlayer