Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save sephirot47/466e29c7cded26d72ae2 to your computer and use it in GitHub Desktop.
Save sephirot47/466e29c7cded26d72ae2 to your computer and use it in GitHub Desktop.
UE4 Get Camera Location or Position and Forward Vector (useful for Tracing)
APlayerCameraManager *camManager = GetWorld()->GetFirstPlayerController()->PlayerCameraManager;
FVector camLocation = camManager->GetCameraLocation();
FVector camForward = camManager->GetCameraRotation().Vector();
@julisinjuly
Copy link

thank you very much!! Great!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment