Get Mesh Rotation C++

I’m using the C++ third person template and I’m trying to store the rotation of the players mesh and then setting the cameras rotation to the same value. I’m new to writing C++ in unreal having only experimented with Blueprint. Any help would be much accreted.

If you want to get the rotation of your character, you must use the following function inside the class that inherits ACharacter.

GetActorRotation();

Unreal Engine 4 Documentation :

For your camera to follow your character you can simply attach.

Awesome, thank you :slight_smile: I wanted to set the camera to its rotation with a button press to reset the camera position :slight_smile: its working perfectly now, thank you :slight_smile: