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

How do I make the part stay behind the player?

game.Players.PlayerAdded:connect(function(Plr)
	Plr.CharacterAdded:connect(function(Char)
		local BackPack=Instance.new("Part",workspace)
		while wait() do
		BackPack.Position=Char.Torso.Position+Vector3.new(0,0,-2)
		end
	end)
end)

this keeps the Part but when he turns it doesn't turn with him, do I need a tool?

1 answer

✓ Accepted answer

Just weld the Backpack to the player's torso, like this:

game.Players.PlayerAdded:connect(function(Plr)
	Plr.CharacterAdded:connect(function(Char)
		local BackPack=Instance.new("Part",workspace)
		local Weld = Instance.new("Weld",BackPack)
		Weld.Part0 = BackPack
		Weld.Part1 = Char.Torso
		Weld.C0 = CFrame.new() --Put the CFrame of the Backpack here
	end)
end)

1 comment

0

Thank you

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