I reworked this a little: I needed layers to orient to a parent’s composition camera.
This is what I got working with your help. Thank you!!
„parent“ ist the name of the Composition containing the Camera called „CameraMain“
delta = toWorld(anchorPoint) - comp("Parent").layer("CameraMain").toWorld([0,0,0]);
radiansToDegrees(Math.atan2(delta[0],delta[2]))
demodern | digital design studio
Cologne, Germany