part = game.Workspace.Dragon:GetChildren() weld = Instance.new("Weld") weld.Part0 = game.Workspace.Dragon.Torso weld.Part1 = part weld.C1 = part.CFrame:toObjectSpace(game.Workspace.Dragon.Torso.CFrame) weld.Parent = game.Workspace.Dragon.Torso part.Anchored = false end
This should Get all the parts in the model and weld it to the torso but it wont work.
for a,b in pairs(game.Workspace.Dragon:GetChildren()) do if b:IsA("BasePart") then weld = Instance.new("Weld") weld.Part0 = game.Workspace.Dragon.Torso weld.Part1 = b weld.C1 = b.CFrame:toObjectSpace(game.Workspace.Dragon.Torso.CFrame) weld.Parent = game.Workspace.Dragon.Torso b.Anchored = false end end
Possibly could be because some of 'Dragons' children are not baseparts. I am not 100% sure because you didn't give any errors from output.