Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
COMMUNITY QUESTION

Why does my weld disappear when I set Part1?

I am trying to attach any part to my character using a ManualWeld and for some reason it doesn't work.

Here's my code:

player.CharacterAdded:connect(function(character)
	local UpperTorso = character:WaitForChild("UpperTorso", 5)
	if UpperTorso then
		local weld = Instance.new("ManualWeld", UpperTorso)
		weld.Part0 = UpperTorso
		weld.Part1 = game.Workspace.Brick
	end
end)

For some reason if I remove Part1 then it appears in UpperTorso, but if I set Part1 to anything, the weld disappears from UpperTorso and doesn't work. Thanks in advance.

1 answer

Set the weld's parent after all other properties are set. Or else thing happen before you want them to.

This discussion is preserved as it was. New answers, comments, and votes are closed.