so im coding my game right now and i want to make it so when the player walks outisde/touches the invisible part, that the door closes but it doesn't work and there is no error showing up. the code is:
local Part = script.Parent
local ExitDoor = game.Workspace:FindFirstChild("ExitDoor")
Part.Touched:Connect(function(hit)
ExitDoor. Transparency = 0
ExitDoor.CanCollide = true
end)