Add HitMarker Sound Effect
This commit is contained in:
parent
e97d370d23
commit
7079c129f7
|
@ -345,6 +345,11 @@ void APlayerCharacter::ProcessHits(TArray<FHitResult> hits)
|
|||
if (!healthComponent->GetIsDead())
|
||||
{
|
||||
OnEnemyHit.ExecuteIfBound();
|
||||
|
||||
if (HitMarkerSound)
|
||||
{
|
||||
UGameplayStatics::PlaySound2D(GetWorld(), HitMarkerSound);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -111,6 +111,9 @@ private:
|
|||
float AimSensitivity;
|
||||
|
||||
float WeaponSpreadMultiplier = 1.0;
|
||||
|
||||
UPROPERTY(EditDefaultsOnly)
|
||||
USoundBase* HitMarkerSound;
|
||||
|
||||
public:
|
||||
// Sets default values for this character's properties
|
||||
|
|
Loading…
Reference in New Issue