Also interesting to note…that I got it working, but decided to figure out what I had originally done wrong and broke it again. After some tweaking, I turned off UseControllerRotationYaw and set the player controller camera manager to view pitch, roll, and yaw all from 0 - 360. All this while using this code using quaternions:
void ACodeOrvoCharacter::handleRotation()
{
float TargetPitch = 0.0f;
switch (gstate)
{
case EGravityState::GS_NORTH:
break;
case EGravityState::GS_EAST:
TargetPitch = -90.0f;
break;
case EGravityState::GS_WEST:
TargetPitch = 90.0f;
break;
case EGravityState::GS_SOUTH:
TargetPitch = 180.0f;
break;
}
FRotator CurrentRot = GetActorRotation();
CurrentRot.Roll = 0.0f;
FRotator TargetRot(TargetPitch, CurrentRot.Yaw, CurrentRot.Roll);
FQuat desired = FQuat::Slerp(CurrentRot.Quaternion(), TargetRot.Quaternion(), .25f);
//CurrentRot = FMath::Lerp(CurrentRot, TargetRot, .25f);
this->SetActorRotation(desired);
}
and it worked. My dumb self wanted to see if quaternions were truly necessary so I uncommented the Lerp and changed code accordingly, now I can no longer reproduce the working project.