I have tried making a block disappear after two seconds by what I know, this is what I came up with:
function onTouch()
game.Workspace.Part.Transparency = 0.5
wait(2)
game.Workspace.Part.CanCollide = false
game.Workspace.Part.Transparency = 1
end
end
connect:OnTouch()
I tried to test it by playing solo, but it didn't respond for more than ten minutes! Is this a problem with Roblox or did my script crash the game? Please help!

1 comment
Why do you have two ends? You only need one. Also, please format your code from now on...