My APawn not spawn on player start when I implement SetupPlayerInputComponent(UInputComponent PlayerInputComponent)*. In case of deletion of that function my APawn spawn correctly. Snipet of SetupPlayerInputComponent
void AMyPawn::SetupPlayerInputComponent(UInputComponent* PlayerInputComponent)
{
Super::SetupPlayerInputComponent(PlayerInputComponent);
PlayerInputComponent->BindAxis("UpDown", this, &AMyPawn::MoveUpDown);
}
void AMyPawn::MoveUpDown(float Value)
{
FVector Location = GetActorLocation();
SetActorLocation(FVector(0, 0, Location.Z + Value));
}
Why when I comment that the player start work ?