(정리를 위한 글) [Unreal 5] Movement Functions

순후추·2024년 3월 7일

Unreal5

목록 보기
1/3
AddMovementInput()
AddControllerPitchInput()
PlayerInputComponent->BindAxis(TEXT("MoveForward"), this, &AShooterCharacter::MoveForward)
PlayerInputComponent->BindAction(TEXT("Jump"), EInputEvent::IE_Pressed, this, &ACharacter::Jump);
AddControllerPitchInput()를 이용하여 마우스 움직임을 구현하면 아래와 같이 프레임에 안 맞는 문제가 생길 수 있다.

따라서 AddControllerPitchInput(AxisValue RotationRate GetWorld()->GetDeltaSeconds()); 이런 방식으로 해결 할 수 있다. AddMovementInput()는 이미 속도라는 것을 가정하고 프레임에 맞게 연산되기 때문에 할 필요가 없다.
profile
게임 개발 블로그

0개의 댓글