Laggy tweenservice

the code:

while true do wait()

	local Pitch = script.Main.Value.Main.Orientation.X 

	local Roll = script.Main.Value.Main.Orientation.Z/ -58.139534883720930232558139534884
	
	------------

	script.motors.Value.Roll1.Motor.DesiredAngle = Roll
	

	function move(obj, pos)
		obj:TweenPosition(pos, "Out", "Linear", 0)
	end
	
		move(script.screen.Value.Screen1.SurfaceGui.Frame.Move, UDim2.new(0,-9,0,Pitch))

		

end

as you can see in the video the roll is done with motor6D and its very smooth,the pitch which I couldnt do with motor6D moves very choppy and I ve tried everything and I still cant fix it. Any solutions or a new approach?

In general, you want to tween on the client rather than the server. As you’re tweening inside of a while true do loop, the constant communication between the server and client is most likely increasing the latency, and so replication starts becoming slower and less accurate, which is why it may appear laggy or choppy.

I switched it from scale to offset and now it works

1 Like