# Spectator does not rotate(pitch) when using CameraComponent

**URL:** <https://forums.unrealengine.com/t/spectator-does-not-rotate-pitch-when-using-cameracomponent/453000>\
**Category:** Cinematics & Media\
**Tags:** shooter-game, spectator, unreal-engine, Multiplayer, question\
**Created:** [July 29, 2019, 7:13am UTC](https://forums.unrealengine.com/t/spectator-does-not-rotate-pitch-when-using-cameracomponent/453000 "2019-07-29T07:13:54Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![anonymous\_user\_d5e5d14a1](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@anonymous\_user\_d5e5d14a1](https://forums.unrealengine.com/u/anonymous_user_d5e5d14a1)\
**Post date:** [July 29, 2019, 7:13am UTC](https://forums.unrealengine.com/t/spectator-does-not-rotate-pitch-when-using-cameracomponent/453000/1 "2019-07-29T07:13:54Z")

</div>

Hello,

my spectator does not receive any pitch rotation from the followed player.

* * *

I am trying to work with ShooterGame project to make a proof of concept FPS spectator feature.  
I’ve added code in GameMode which switches VictimPlayer to a spectator mode:

```
VictimPlayerState->bIsSpectator = true;
PlayerController->ChangeState(NAME_Spectating);
PlayerController->ClientGotoState(NAME_Spectating);

```

I’ve also added logic to a PlayerController which switches the spectator’s view to the next player:

```
void AShooterPlayerController::BeginSpectatingState()
{
	Super::BeginSpectatingState();

	ServerViewNextPlayer();
}

```

And it’s working perfetly fine. **But if I add CameraComponent to the ShooterCharacter - my spectator does not recieve any pitch rotation.**

```
AShooterCharacter::AShooterCharacter(const FObjectInitializer& ObjectInitializer)
	: Super(ObjectInitializer.SetDefaultSubobjectClass<UShooterCharacterMovement>(ACharacter::CharacterMovementComponentName))
{

	FirstPersonCameraComponent = CreateDefaultSubobject<UCameraComponent>(TEXT("FirstPersonCamera"));
	FirstPersonCameraComponent->SetupAttachment(GetCapsuleComponent());
	FirstPersonCameraComponent->RelativeLocation = FVector(-39.56f, 1.75f, 64.f); // Position the camera
	FirstPersonCameraComponent->bUsePawnControlRotation = true;

	Mesh1P = ObjectInitializer.CreateDefaultSubobject<USkeletalMeshComponent>(this, TEXT("PawnMesh1P"));
	Mesh1P->SetupAttachment(FirstPersonCameraComponent);
	GetMesh()->SetupAttachment(FirstPersonCameraComponent);
...

```

What am I missing here? I believe CameraComponent is a standard way to change the default’s camera position, so spectator mechanism should support this.  
I will be grateful for any help.

---

<div class="post-metadata">

**Author:** ![anonymous\_user\_d5e5d14a1](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@anonymous\_user\_d5e5d14a1](https://forums.unrealengine.com/u/anonymous_user_d5e5d14a1)\
**Post date:** [July 29, 2019, 5:49pm UTC](https://forums.unrealengine.com/t/spectator-does-not-rotate-pitch-when-using-cameracomponent/453000/2 "2019-07-29T17:49:46Z")

</div>

Turns out that “Use Controller Rotation Pitch” has to be set to true(Yaw is true by default) on Pawn.  
Issue solved.
