I am trying to make a fnaf like game, i am having trouble with the camera movement system, It's really buggy and just moves everywhere, how do i fix this? Example: https://gyazo.com/71b694f55a2244b5922baa9a3c8e1830 What i want it to be like: https://gyazo.com/44368d69dada53f60f0745f44fbeb1f6
local Player = game:GetService("Players").LocalPlayer
local Cursor = Player:GetMouse()
local Camera = workspace.CurrentCamera
wait(1)
local part = Player.Character.Head
repeat wait(1) until Player.Character.Parent == workspace
Camera.CameraSubject = Cursor
Camera.CameraType = Enum.CameraType.Scriptable
Camera.CFrame = part.CFrame
Cursor.Move:Connect(function()
wait(0.1)
Camera.CFrame = CFrame.new(part.Position, Cursor.Hit.p)
end)
