Bugfix Set Mouse Input to Only Poll Yaw Movement

This commit is contained in:
Philip W 2023-02-02 02:19:59 +00:00
parent 0a7025b684
commit 9e451d4539
2 changed files with 4 additions and 4 deletions

Binary file not shown.

View File

@ -29,12 +29,12 @@ void ATempCharacter::BeginPlay()
//Binds the input we made in the setup player component to the forward vector
void ATempCharacter::ForwardInput(float Axis)
{
AddMovementInput(GetActorForwardVector() * Axis);
AddMovementInput(UKismetMathLibrary::GetForwardVector(FRotator(0, GetControlRotation().Yaw, 0)) * Axis);
}
//Binds the input we made in the setup player component to the right vector
void ATempCharacter::RightMoveInput(float Axis)
{
AddMovementInput(GetActorRightVector() * Axis);
AddMovementInput(UKismetMathLibrary::GetRightVector(FRotator(0, GetControlRotation().Yaw, 0)) * Axis);
}