How do I make this smoother?

I am making a plane right now and it points towards the players mouse.
Its not very smooth right now when it turns so I was wondering if there is a way to make it smoother?

-- client
flyEvent:FireServer(plane)-- makes it fly
wait(3)
repeat
	wait(0.5)
sendMouse:FireServer(plane, mouse.Hit.Position) -- change where its facing
until plane:FindFirstChild('On').Value == 0
--server
sendMouse.OnServerEvent:Connect(function(player, plane, po)-- stats
	plane.CFrame = CFrame.lookAt(plane.Position, po)-- points it in the direction
end)

T w e e n S e r v i c e (is your best friend)

You could use CFrame Lerping. Or use VectorForces + AlignOrientation for a more realistic outcome.

I personally use a combination of Runservice and Nevermore engines spring module to make my helicopter “smooth”
don’t pay attention to my bad piloting skills.

The code is not very good and the controls for the thing are pretty difficult, but hopefully you can learn something
MaloniHelicopter.rbxl (240.4 KB)

Ok So I am using tween service and its flying all over the place now.
Do you know why?

You should set the network ownership of the plane assembly to the player, then have the player’s client control the physics of the plane (don’t have it anchored).

For you server code:

  • Wait for a player to sit in the seat
  • Use BasePart:SetNetworkOwner to set the network owner to the player who sat
  • When the player gets out of the seat set the network owner back to the server (nil)

For your client code:

  • Make sure the script’s run context is client. Put the script inside the seat
  • When someone sits in the seat, check if it’s the local player.
  • If it is the local player, start controlling the physics of the plane. (Probably use the physics objects or use raw impulse stuff. I only know how to use the old body movers.)
  • Once the local player’s character gets out of the seat stop trying to control the plane.

This is the best way to make a super responsive* plane, and it’s interpolated with physics so it’s super smooth.

* Doesn’t need to wait for client input to go to the server and back, so it’s more responsive than methods that require this.