Camera Rotation System Of Free Cam Movement


I’m Trying to look a way to keep Z Rotation keep on 0, Any Way to fix this?

if UserInpurService:IsMouseButtonPressed(Enum.UserInputType.MouseButton2) then
UserInpurService.MouseBehavior = Enum.MouseBehavior.LockCurrentPosition
local MouseDelta = UserInpurService:GetMouseDelta()
local X,Y = math.rad(MouseDelta.X), math.rad(MouseDelta.Y)
Camera.CFrame *= CFrame.Angles(-Y,-X,0)

else
UserInpurService.MouseBehavior = Enum.MouseBehavior.Default
end