Hello again developers! I have designed a simple part script that upon clicking a part, it waits a second and destroys the part.
local High = script.Parent.Highlight
local sound = Instance.new("Sound")
sound.SoundId = "rbxassetid://138108873"
sound.Parent = Part
local player = game.Players.LocalPlayer
Part.ClickDetector.MouseHoverEnter:connect(function()
High.Enabled = true
Part.ClickDetector.MouseClick:connect(function()
wait(1)
Part:Destroy()
end)
end)
Part.ClickDetector.MouseHoverLeave:connect(function()
High.Enabled = false
end)
Although it looks off knowing the player sort of jump breaks it with their mind. I wish I could make it so the player walks up to the part and faces it before they destroy it so I can add a breaking animation later!