Part mysteriously going back to its original position after Weld has been disabled

So I’ve been having this problem; I’ve been using a local script for this (since the game is local-based) and i have a ‘plank’ holding system.

The thing is; The plank goes to its original position after being dropped.
I don’t know if it is some basic Roblox Physics law or something, but I’ve been struggling a lot with this problem.

Here’s the fragment that handles this system. This loops for each plank found inside a folder in workspace.

clk.MouseClick:Connect(function(plr)
		if plr == game.Players.LocalPlayer then
			if not enabled then
				enabled = true

				grip.Parent = v
				grip.Part1 = v
				grip.Part0 = ch:WaitForChild('RightHand')

				grip.Enabled = true

				v.CanCollide = false
				load:Play()

				local ui = script:WaitForChild('DropUI'):Clone()
				ui.Parent = game.Players.LocalPlayer.PlayerGui

				game.TweenService:Create(ui.Button, TweenInfo.new(0.5, Enum.EasingStyle.Back, Enum.EasingDirection.Out), {Position = UDim2.new(.5,0,.85,0)}):Play()

				ui.Button.MouseButton1Click:Once(function()

					grip.Enabled = false
					v.CanCollide = true
					load:Stop()

					game.TweenService:Create(ui.Button, TweenInfo.new(0.3, Enum.EasingStyle.Cubic, Enum.EasingDirection.In), {Position = UDim2.new(.5,0,1,0)}):Play()

					wait(.5)

					enabled = false
					ui:Destroy()
				end)
			end
		end
	end)
3 Likes

I think it’s because the server doesn’t know it moved, so physics on the server replicated that position to the client. Use SetNetworkOwner() to the player holding the plank so that physics is handled by that player while its being held. Be sure to set it to nil when dropped though.

1 Like