Camera [NEED HELP]

Is there any way how to make player still able to move the camera a little bit using their mouse even though the camera is tweening, I know how to move camera , well from this forum with :

local Mouse = game.Players.LocalPlayer:GetMouse()
local Camera = game.Workspace.CurrentCamera

local DefaultCFrame = Camera.CFrame
local Scale = 200

function Update()
    -- get the center of the screen
    local Center = Vector2.new(Camera.ViewportSize.X/2, Camera.ViewportSize.Y/2)
    -- get the movement (it's in studs, and the mouse properties are in pixels, so you want to divide it by your scale to not move the camera really really far)
    local MoveVector = Vector3.new((Mouse.X-Center.X)/Scale, (Mouse.Y-Center.Y)/Scale, 0)
    -- CFrame * CFrame makes it work the same regardless of rotation, where addition just makes it work for one direction
    Camera.CFrame = DefaultCFrame * CFrame.new(DefaultCFrame.p + MoveVector)
end

game:GetService("RunService").RenderStepped:Connect(Update)

And I also make this for the tweening camera (Moving Camera Background)

local tweenservice = game:GetService("TweenService")

local cam = workspace.Camera
local scenes = workspace.CameraScenes

repeat wait() until cam.CameraSubject ~= nil

cam.CameraType = Enum.CameraType.Scriptable

while true do
	for i, v in pairs(scenes:GetChildren()) do
		cam.CFrame = v["1"].CFrame
		local currentTween = tweenservice:Create(cam, TweenInfo.new(10), {CFrame = v["2"].CFrame})
		currentTween:Play()
		wait(10)
	end
end

Both are local script, so how to combine, player can move the camera a little bit while their cursor move, maybe like 5 degree or similar to that calculation, but the tweening still work. So is like the camera still tweening but while tweening, player can still also move the camera a little if they move their cursor. I give one game example : Sharkuses Sandhurst Military Academy, like on their Main Menu

1 Like