Question about despawning blocks

Hello, I’m making a destruction game and I want to know how to make the studs disappear after the explosion.
Script:

script.Parent.Touched:Connect(function()
	local ex = Instance.new("Explosion")
	ex.BlastRadius = 5
	ex.Position = script.Parent.Position
	ex.Parent = script.Parent
	ex.DestroyJointRadiusPercent = 1
	ex.BlastPressure = 50000
	ex.TimeScale = 1
	wait(1)
	script.Parent:Destroy()
end)

I want for the script to detect blocks affected by the explosion and despawn them.

So correct me if I’m wrong, but according to the API reference explosions have a hit event.

you could connect the explosion with the hit event which returns the hit parts, then use debris service with those parts to despawn them after x amount of time.

local debris = game:GetService("Debris")
local despawntime = 5
ex.Hit:Connect(function(part)
   debris:AddItem(part, despawntime)
end)