It was working last night before I logged off but now a touch interest brick that opens up a door when walked through will not work. Maybe the problem isn't within the script-- I'm just not really sure what to do. Please help.
(Here's the script:)
print("One Way Door Script Loaded")
Button = script.Parent
Door1 = script.Parent.Parent.Door1
Door2 = script.Parent.Parent.Door2
Door3 = script.Parent.Parent.Door3
Door4 = script.Parent.Parent.Door4
Door5 = script.Parent.Parent.Door5
Door6 = script.Parent.Parent.Door6
Door7 = script.Parent.Parent.Door7
Door8 = script.Parent.Parent.Door8
Door9 = script.Parent.Parent.Door9
function onTouched(hit)
print("Door Hit")
Door2.Transparency = 1
Door2.CanCollide = false
wait(.001)
Door1.CanCollide = false
Door1.Transparency = 1
Door3.CanCollide = false
Door3.Transparency = 1
wait(.001)
Door4.CanCollide = false
Door4.Transparency = 1
Door5.CanCollide = false
Door5.Transparency = 1
wait(.001)
Door6.CanCollide = false
Door6.Transparency = 1
Door7.CanCollide = false
Door7.Transparency = 1
wait(.001)
Door8.CanCollide = false
Door8.Transparency = 1
Door9.CanCollide = false
Door9.Transparency = 1
wait(2.2)
Door9.CanCollide = true
Door9.Transparency = 0
Door8.CanCollide = true
Door8.Transparency = 0
wait(.001)
Door7.CanCollide = true
Door7.Transparency = 0
Door6.CanCollide = true
Door6.Transparency = 0
wait(.001)
Door5.CanCollide = true
Door5.Transparency = 0
Door4.CanCollide = true
Door4.Transparency = 0
wait(.001)
Door3.CanCollide = true
Door3.Transparency = 0
Door1.CanCollide = true
Door1.Transparency = 0
wait(.001)
Door2.CanCollide = true
Door2.Transparency = 0
end
script.Parent.Touched:connect(onTouched)
|