How can I clone multiple things from a folder, upon a function?

So, i got this Humanoid based crate, it clones stuff upon death. All though crude, it works as inteded.
However, I have no idea how to make it so it clones multiple stuff instead of just one thing, like in HL2.

image

image

You would have to clone every item individually, however if you want the same things to happen to every cloned item then you can use a loop to clone each item

You should use a for loop

for index, value in pairs(children) do

   local clonedPart = v:Clone()
   clonedPart.Anchored = true
   clonedPart.CFrame = SomeOtherPart.CFrame * CFrame.new(1,0,0)
   clonedPart.Parent = workspace

end

This code should go inside the myHuman.Died event

1 Like