Change `TargetArmLength` and `SocketOffset` in CameraBoomComponent on PlayerCharacter
This commit is contained in:
parent
6d8dd33bda
commit
ba6c614116
|
@ -30,16 +30,16 @@ APlayerCharacter::APlayerCharacter()
|
|||
CameraBoom->SetupAttachment(RootComponent);
|
||||
CameraBoom->bDoCollisionTest = true;
|
||||
CameraBoom->bUsePawnControlRotation = true;
|
||||
CameraBoom->TargetArmLength = 500.0f;
|
||||
CameraBoom->TargetArmLength = 350.0f;
|
||||
CameraBoom->bEnableCameraLag = true;
|
||||
CameraBoom->CameraLagSpeed = 10.0f;
|
||||
CameraBoom->SocketOffset = { 0.0f, 0.0f, 220.0f };
|
||||
CameraBoom->SocketOffset = { 0.0f, 75.0f, 110.0f };
|
||||
|
||||
// Setup the camera component
|
||||
CameraComponent = CreateDefaultSubobject<UCameraComponent>(TEXT("CameraComponent"));
|
||||
CameraComponent->SetupAttachment(CameraBoom, USpringArmComponent::SocketName);
|
||||
CameraComponent->bUsePawnControlRotation = false;
|
||||
CameraComponent->SetRelativeRotation({ -10.0f,0.0f,0.0f });
|
||||
CameraComponent->SetRelativeRotation({ -5.0f,0.0f,0.0f });
|
||||
|
||||
// Setup the character movement
|
||||
UCharacterMovementComponent* CharacterMovementComponent = GetCharacterMovement();
|
||||
|
|
|
@ -65,10 +65,10 @@ protected:
|
|||
|
||||
private:
|
||||
|
||||
UPROPERTY()
|
||||
UPROPERTY(EditAnywhere, BlueprintReadWrite, Meta = (AllowPrivateAccess = "true"))
|
||||
USpringArmComponent* CameraBoom = nullptr;
|
||||
|
||||
UPROPERTY()
|
||||
UPROPERTY(EditAnywhere, BlueprintReadWrite, Meta = (AllowPrivateAccess = "true"))
|
||||
UCameraComponent* CameraComponent = nullptr;
|
||||
|
||||
float DefaultMovementSpeed;
|
||||
|
|
Loading…
Reference in New Issue