well uh read the title...
COMMUNITY QUESTION
How to weld a model to player's torso?
3 answers
game.Players.PlayerAdded:Connect(function(Player)
Player.CharacterAdded:Connect(function(Char)
local Part = Char:WaitForChild("HumanoidRootPart")
local Weld = Instance.new("Weld", Char)
WhatYouWantToWeld.CFrame = Part.CFrame
Weld.Part0 = Part
Weld.Part1 = WhatYouWantToWeld
Weld.C0 = Part.CFrame:inverse()
Weld.C1 = WhatYouWantToWeld.CFrame:inverse()
end)
end)
2 comments
0
the thing i want to weld gotta be somewhere specific or i can just get it from workspace?
0
also does it work with unions and models? because this is what i try to weld
you can try this model of mine, which was months ago, i hope you get what the scripts say: https://www.roblox.com/library/868174364/R6-ONLY-Welding-Basics-by-anphu04
As shown in the wiki http://wiki.roblox.com/index.php?title=Weld. Note that im using a serverscript.
---- Weld Function taken from wiki (note only 2 parts can weld with this function)----
local function weldBetween(a, b)
--Make a new Weld and Parent it to a.
local weld = Instance.new("ManualWeld", a)
--Get the CFrame of b relative to a.
weld.C0 = a.CFrame:inverse() * b.CFrame
--Set the Part0 and Part1 properties respectively
weld.Part0 = a
weld.Part1 = b
--Return the reference to the weld so that you can change it later.
return weld
end
--- NOTE: if its r15 Torso is called LowerTorso or UpperTorso. In r6 its Torso. For simplicity lets use HumanoidRootPart
game.Players.PlayerAdded:connect(function(player)
player.CharacterAdded:connect(function(character)
local ChosenPart = ""-- place something that you want to weld to torso
weldBetween(ChosenPart,character("HumanoidRootPart")
end)
end)
This discussion is preserved as it was. New answers, comments, and votes are closed.

4 comments
i tried many things but nothing worked
Your question is a bit confusing. A backpack in itself is not a tool but contain tools. A backpack store tools. So is it that you want a custom backpack or tools that doesnt use the "orange hammer" item that is default by roblox
i just wanna weld something to player's torso when they join the game
and i dont know how :|