function Step()for s=#garbage,1,-1 do local W=garbage[s]local c=W[1]local E=W[2]local F=W[3]local n=tick()-E if n>=F then if type(c)=="\116\097\098\108\101"then for s,W in ipairs(c)do W:Destroy()end else c:Destroy()end table.remove(garbage,s)end end end;(coroutine.wrap(function()while _L.Services.RunService.Heartbeat:Wait()do Step()end end))()return function(s,W)if not W then W=10 end table.insert(garbage,{s,tick(),W})end



function Step()
	--- scan garbage for items that are expired and clean them up
	for i = #garbage, 1, -1 do
		local v = garbage[i]
		local obj = v[1]
		local t = v[2]
		local removetime = v[3]
		local tp = (tick() - t)
		if tp >= removetime then
			if type(obj) == "table" then
				for _, objchild in ipairs(obj) do
					objchild:Destroy()
				end
			else
				obj:Destroy()
			end
			table.remove(garbage, i)
		end
	end
end


coroutine.wrap(function() --- main loop
	while _L.Services.RunService.Heartbeat:Wait() do
		Step()
	end
end)()


return function(obj, t)
	if not t then
		t = 10
	end
	--- add to garbage
	table.insert(garbage, {obj, tick(), t})
end
