I tried making this but it didnt work. It disappeared and came back but nothing happened when I clicked it.
My code:
script.Parent.ClickDetector.MouseClick:Connect(function(player)
script.Parent.Transparency = 1
script.Parent.CanCollide = false
script.Parent.ClickDetector:Destroy()
wait(10)
script.Parent.Transparency = 0
script.Parent.CanCollide = true
local click = Instance.new("ClickDetector")
click.Parent = script.Parent
end)
Please help!

1 comment
Yoy could also just change the selection distance to 0 and it would do the same thing, withput having to move the click detector.