When you say you “got (Pitch:0, Yaw:180, Roll:0)” - where did you get it?
You can certainly create an FRotator that only has pitch rotation:
FRotator MyPitchRotator = FRotator();
MyPitchRotator.Pitch = 90.0f;
//or
FRotator MyPitchRotator(90.0f, 0.0f, 0.0f);
Or you can retrieve the current rotation and retain only the Pitch value:
FRotator MyPitchRotation = MyPawn->GetActorRotation();
MyPitchRotation.Yaw = 0.0f;
MyPitchRotation.Roll = 0.0f;
Or, if you like, you can just retrieve and work with the pitch value itself:
float MyPitchRotation = MyPawn->GetActorRotation().Pitch;
If you are retrieving the rotation from a scene component (UStaticMesh etc.) within your Pawn, the rotation you receive is the actual component’s rotation. You may find that your Pawn’s local (relative) orientation is different from its world orientation (i.e. pitch, roll, and yaw may be different apparent axes is local space than they are in world space).
You can specify which space you are working with by using GetComponentRotation, SetComponentRotation, and AddWorldRotation vs. AddLocalRotation, AddRelativeRotation, and SetRelativeRotation (there is no GetLocal or GetRelativeRotation because you can access the RelativeRotation member variable of the component directly, MyComponent->RelativeRotation).
It might be easier for you to use Quaternions, rather than Eulers, especially if you’re trying to work around the 90± limits and gymbal lock. You can use all the same methods to pass Quats in, and it’s easier to constrain rotation to specific axes. The FQuat constructor has a version that allows to to give it an axis around which to rotate, and the amount of rotation to apply (in radians, not degrees). You can use it like this:
FQuat MyQuatRotation = FQuat(FVector::RightVector, FMath::DegreesToRadians(Degrees));
//or
FQuat MyQuatRotation(FVector::RightVector, FMath::DegreesToRadians(Degrees));
The first argument is the axis around which to rotate, you can enter any vector you like. Here I’m using FVector’s static RightVector value, which corresponds to rotation around Y, which is Pitch.
FMath::DegreesToRadians converts your Degrees value into a radians value, allowing you to continue your rotation calculation based on the often more intuitive degrees.
Once you have your quat, you can easily manipulate it as needed, and pass it to SetRelativeRotation etc. as you would an FRotator - but without any of the hassle of gymbal lock, etc.
You can also retrieve a quat from the returned values of GetActorRotation/GetComponentRotation, or from the MyComponent->RelativeRotation value:
FQuat MyActorRotation = MyPawn->GetActorRotation().Quaternion();
FQuat MyCompWorldRotation = MyComponent->GetComponentRotation().Quaternion();
FQuat MyCompRotation = MyComponent->RelativeRotation.Quaternion();