Download

Toggle Between First and Third Person Cameras

This is my first contribution for the community. After searching and searching how to accomplish toggling between two cameras attached to the same character/pawn/actor/what have you, here is my solution. As stated this is only for cameras attached to the same character/pawn. In the future I may try swapping to a camera attached to say a rifle that the character is holding. Hope some will find this useful.



void APlayerCharacter::TogglePerspective()
{
	if (FPC->bIsActive)
	{
		FPC->Deactivate();
		TPC->Activate();
		return;
	}
	if (TPC->bIsActive)
	{
		TPC->Deactivate();
		FPC->Activate();
		return;
	}
}