Hello, I made a camera that hovers over an object but when I press an arrow to go to the next object. I want the camera to rotate around the object and when the arrow is pressed I want the camera to still be rotating and not reset when switched.
my code:
local function CamTween(obj)
Camera.CameraType = Enum.CameraType.Scriptable
local cf = CFrame.new(obj.Position + Vector3.new(0,80,0),obj.Position)
local Objectcam = TweenService:Create(Camera, TweenInfo.new(0.75,Enum.EasingStyle.Quint,Enum.EasingDirection.InOut,0,false,0), {CFrame = cf})
Objectcam:Play()
end
This function gets called everytime the arrow is pressed so the camera gets moved to the next object. How can I make the camera orbit the object without it resetting each time the arrow is pressed?