Weird woble with blocks


How could I fix this wobble that it’s having sometimes?
that part of the script:

event5.OnServerEvent:Connect(function(plr,mouseTarget)
	Model.Parent = workspace.Placing
	stop()
	Model.PrimaryPart.Anchored = false
    Model.PrimaryPart.CanCollide = false
	Model.PrimaryPart.Massless = true
	Model.PrimaryPart.Part.Massless = true
	local we = Model.PrimaryPart.Weldno
	we.Part0 = mouseTarget.Parent
	we.Part1 = nil
	Model.PrimaryPart.CFrame = mouseTarget.CFrame:ToWorldSpace(CFrame.new(0,0,-2))*CFrame.Angles(math.rad(Diff),math.rad(Elev),math.rad(Rot))
	we.Part1 = Model.PrimaryPart
	if Elev == 360 then Elev = 0 end if Diff == 360 then Diff = 0 end if Rot == 360 then Rot = 0 end
	if Elev == -360 then Elev = 0 end if Diff == -360 then Diff = 0 end if Rot == -360 then Rot = 0 end
end)

Event 5 is fired when the mouse is over a block
Diff/Elev/Rot is the rotations
the block cannot be anchored while the mouse is over another block

I think I should only fire event5 when the Mouse.Target changes. but how could I do that?

Why does the block need to be unanchored? The problem seems to be that the remote firing cannot keep up with the gravity trying to pull the block downward.

The block needs to be unanchored because it needs to move. It should be part of a vehicle. I guess set the velocity to 0 then? i did set it to massless tho

Maybe instead of keeping it unanchored while you’re moving it. You should instead anchor it while moving it and unanchor when the player stops moving the block.

You can be placing it while the vehicle is moving tho.
setting the velocity to 0 seemed to help but not fully solve the cracks
Capture_2020_05_05_16_04_57_692
it still has cracks tho, but thats for another topic.