My restricted door worked fine but now it doesn't I've tried as much as I can and it's still broken, here's the code. Please help.
01 | local door = script.Parent |
02 |
03 | function open() |
04 | -- This function will open the door. |
05 | door.CanCollide = false -- Make players able to walk through the door. |
06 |
07 | for transparency = 0 , 1 , . 1 do |
08 | door.Transparency = transparency |
09 | wait(. 1 ) |
10 | end |
11 | end |
12 |
13 | function close() |
14 | -- This function will close the door. |
15 | for transparency = 1 , 0 , -. 1 do |
I tried running this on Roblox and it looks like on line 47 you are missing an or at the end, which is causing your problem, try switching line 47 from player.Name == "AncientDinoDan"
to player.Name == "AncientDinoDan" or
As Aresko said, you are missing an or on line 47. I would also recommend adding a Debounce to your door script. Basically, the script will run for each of your limbs that touches the door. If you add a debounce, then it will only run once.
http://wiki.roblox.com/index.php?title=Debounce