in your trace, it seems the camera manager is just a manager, that is likely placed at (0,0,0) or god knows where. You need the actual camera object transform as the source of ForwardVector. The rest seems fine. Can also toggle DrawDebug enum to see where the trace realy going
As for polar coordinates: you getting the cortesian point via this trace and then converting it to system you need. Idk if there is a default function for this, but writing conversion manually isn’t that hard. Accoding to wiki it’s just the
It’s exactly where the player controller’s current view target is in WS, and the direction matches, too - it’s a universal way of obtaining data regardless of which camera we’re using. It is, essentially, current camera.
None of it matters here, though since we’re using world origin 0,0,0 as trace start - so we’re definitely not tracing from the right place unless the player is, indeed, the very centre of the world.
@ViaCognita Not sure what output you’re expecting, do you even need to trace? Perhaps you could clarify what this is for? If you want a universal heading, you can (and/or convert it to degrees):
The player will be inside a sphere. The player will be at the origin (0.0f, 0.0f, Z), and the sphere will have a 750.0f radius. By the way, I’m using Z because I don’t know which value to use here.
I need the polar coordinates because I want to compute on which point of the sphere’s surface the player is looking at. Yes, I know that I can use line trace for objects to line a trace to the sphere and know that location, but I’m using this to learn more about Unreal, specially about polar coordinates.