i tried making some kind of prop thing and when you hit it it unanchors it but it takes too long but why does it?

script:

local debounce = false
script.Parent.Hitbox.Touched:Connect(function(hit)
	if debounce == false then
		if hit.Parent.Parent:FindFirstChild("Speed") then
			wait()
			for i,parts in pairs(script.Parent.Parts:GetDescendants()) do
				if parts:IsA("BasePart") then
					parts.Anchored = false
					parts:BreakJoints()
					script.Parent.Parts.Part.Sound:Play()
					script.Parent.Parts.Used.Value = true
					debounce = true
				end
			end
			end
	end
end)

thanks