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

After lot of time I re script it and finally fixed it!

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.