I have tried many methods to get the camera's Y angle, and I have a slight intuition that I can obtain the Y angle using some trigonometry, but I don't know how to do that. How do I get the current camera's y angle in degrees as a full 360° rotation?
I've already tried these methods:
local cam = workspace.CurrentCamera
-- eg #1
local ex, ey, ez = cam.CFrame:ToEulerAnglesXYZ()
local rotation = ey -- this give the values from -2 to 1. ????
-- eg #2
local rotation = cam.CFrame.Angles() -- error
-- eg #3
local rotation = math.asin(cam.CFrame.lookVector.Y)

1 comment
Use trigonometry to get the angle between two points. Use LookVector "The forward-direction component of the CFrame’s orientation."