Character movement mode flying mode to walking

When i change from flying mode(i can rotate in the yaw and pitch axis) to walking(i can rotate in the yaw and pitch axis only when im walking) mode my gravity stops ( i remain in the air) and my rotation locks where my flying rotation was, wich is not the default one so i hoped i could reset my rotation too

my code:

void ANeverAgainCharacter::FloatJetpack(float Value)
{
if ((Controller != NULL) && (Value != 0.0f))
{
//try

	impulse = forceValue * time;
	AddMovementInput(GetActorForwardVector(), impulse);
      GetCharacterMovement()->SetMovementMode(EMovementMode::MOVE_Flying);
	  GetCharacterMovement()->bCheatFlying = true;
	 
	

}
else
{
	GetCharacterMovement()->SetMovementMode(EMovementMode::MOVE_Walking);
	GetCharacterMovement()->bCheatFlying = false;

	


}

}