Skip to content

Commit

Permalink
Merge pull request #13 from Alex-G/main
Browse files Browse the repository at this point in the history
Linux, Android compile error fix
  • Loading branch information
Sixze authored Aug 26, 2021
2 parents a2fa186 + 927f5a6 commit 4bf391a
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 9 deletions.
16 changes: 8 additions & 8 deletions ALS/Source/ALS/Private/AlsCharacter.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -402,8 +402,8 @@ bool AAlsCharacter::CanSprint() const

return LocomotionState.bHasInput &&
(RotationMode != EAlsRotationMode::Aiming || bSprintHasPriorityOverAiming) &&
(ViewMode != EAlsViewMode::FirstPerson &&
(DesiredRotationMode == EAlsRotationMode::VelocityDirection || bRotateToVelocityWhenSprinting) ||
((ViewMode != EAlsViewMode::FirstPerson &&
(DesiredRotationMode == EAlsRotationMode::VelocityDirection || bRotateToVelocityWhenSprinting)) ||
FMath::Abs(FRotator::NormalizeAxis(LocomotionState.InputYawAngle - ViewState.SmoothRotation.Yaw)) < 50.0f);
}

Expand Down Expand Up @@ -487,7 +487,7 @@ void AAlsCharacter::RefreshRotationMode()
return;
}

if (bSprinting && DesiredRotationMode == EAlsRotationMode::Aiming ||
if ((bSprinting && DesiredRotationMode == EAlsRotationMode::Aiming) ||
DesiredRotationMode == EAlsRotationMode::VelocityDirection)
{
SetRotationMode(EAlsRotationMode::LookingDirection);
Expand Down Expand Up @@ -865,8 +865,8 @@ void AAlsCharacter::RefreshGroundedActorRotation(const float DeltaTime)

// Not moving.

if (!TryRefreshCustomGroundedNotMovingActorRotation(DeltaTime) &&
RotationMode == EAlsRotationMode::Aiming || ViewMode == EAlsViewMode::FirstPerson)
if ((!TryRefreshCustomGroundedNotMovingActorRotation(DeltaTime) &&
RotationMode == EAlsRotationMode::Aiming) || ViewMode == EAlsViewMode::FirstPerson)
{
RefreshGroundedNotMovingAimingActorRotation(DeltaTime);
}
Expand Down Expand Up @@ -1811,7 +1811,7 @@ void AAlsCharacter::TryStartRolling(const float PlayRate)
{
StartRolling(PlayRate, LocomotionState.bHasInput &&
(RollingSettings.bRotateToInputOnStart ||
RollingSettings.bRotateToInputDuringRoll && RollingSettings.InputInterpolationSpeed <= 0.0f)
(RollingSettings.bRotateToInputDuringRoll && RollingSettings.InputInterpolationSpeed <= 0.0f))
? LocomotionState.InputYawAngle
: LocomotionState.Rotation.Yaw);
}
Expand All @@ -1820,8 +1820,8 @@ void AAlsCharacter::TryStartRolling(const float PlayRate)
bool AAlsCharacter::IsRollingAllowedToStart(const UAnimMontage* Montage) const
{
return LocomotionAction == EAlsLocomotionAction::None ||
LocomotionAction == EAlsLocomotionAction::Rolling &&
!GetMesh()->GetAnimInstance()->Montage_IsPlaying(Montage);
(LocomotionAction == EAlsLocomotionAction::Rolling &&
!GetMesh()->GetAnimInstance()->Montage_IsPlaying(Montage));
}

void AAlsCharacter::StartRolling(const float PlayRate, const float TargetYawAngle)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ void UAlsAnimNotify_FootstepEffects::Notify(USkeletalMeshComponent* MeshComponen
#endif

const FAlsFootstepEffectSettings* EffectSettings{nullptr};
const EPhysicalSurface SurfaceType{Hit.PhysMaterial.IsValid() ? Hit.PhysMaterial->SurfaceType : SurfaceType_Default};
const auto SurfaceType{Hit.PhysMaterial.IsValid() ? Hit.PhysMaterial->SurfaceType : TEnumAsByte<EPhysicalSurface>(SurfaceType_Default)};

for (const auto& Effect : FootstepEffectsSettings->Effects)
{
Expand Down

0 comments on commit 4bf391a

Please sign in to comment.