// Fill out your copyright notice in the Description page of Project Settings. #include "MyPlayerCharacter/MyCharacter.h" // Sets default values AMyCharacter::AMyCharacter() { // Set this character to call Tick() every frame. You can turn this off to improve performance if you don't need it. PrimaryActorTick.bCanEverTick = true; CameraComponent = CreateDefaultSubobject(TEXT("CameraComponent")); CameraComponent->SetupAttachment(RootComponent); CameraComponent->SetRelativeLocation(FVector(0.0f, 0.0f, 50.0f)); CameraComponent->bUsePawnControlRotation = true; } // Called when the game starts or when spawned void AMyCharacter::BeginPlay() { Super::BeginPlay(); }