I'm trying to make your head go wherever you're looking up and down (R6) this is what I have:

local plr = game.Players.LocalPlayer
local char = plr.Character
local mouse = plr:GetMouse()

game:GetService('RunService').RenderStepped:connect(function()
	local dir = mouse.UnitRay.Direction.unit
		
	local hrot = char.HumanoidRootPart.CFrame * CFrame.new(0, 1.5, 0) * CFrame.new(char.Humanoid.CameraOffset)
	char.Torso.Neck.C0 = char.Torso.CFrame:toObjectSpace(hrot)
		
	if dir.y == dir.y then
		local rot = -math.asin(dir.y)
		char.Torso.Neck.C1 = CFrame.Angles(rot, 0, 0)
	end
end)

The problem is it only works in third person but I want it to work in first person (first person locked game.)