UGameplayStatics::SpawnSound vs. UAudioComponent

Hey all,
I took a crack at implementing this earlier in the series and decided on the solution of having an AudioComponent attached to the ShooterCharacter and using AudioComponent.Play() to play the sound.

I’m wondering in which situations this is preferable to using GameplayStatics::SpawnSound methods. Seems based on documentation that the Gameplay statics essentially creates an audio component on the Actor anyway? Is it more performant to already have an audio component on the actor? Seems like it also would be easier to manage in terms of having 1 component only handle one thing.

Just a curiosity question… Hopefully someone can help!

If it’s a fire and forget then you don’t need to keep it around which is what would happen if you add a audio component to your class.

1 Like

This topic was automatically closed 20 days after the last reply. New replies are no longer allowed.

Privacy & Terms