Stopping an sound (by destroying it)

I’m having issues trying to destroy a sound that’s placed (not spawned). I don’t want to spawn it because it won’t work in my situation. I tried making a function inside of the level blueprint, but I can’t call it from my other blueprint. I have something that if you press E on it, I want the sound cue (its called Crickets) to get destroyed or at least stop playing sound. I can’t call the actor or cast to it, not sure why. If anyone knows a solution or how to reference the crickets, please help me. Thanks!

Hi, I think this should work.

When you press the E key use “Get All Actors Of Class” and select the class of the actor(s) you want retrieved that are in the world.
https://docs.unrealengine.com/latest/INT/BlueprintAPI/Utilities/GetAllActorsOfClass/index.html

Now feed the returned array into a “ForEachLoop.” You should now be able deactivate/destroy the actors.

Thanks it worked. But it will kind of mess up if I want to have more AmbientSounds. Am I able to check the name and only delete it if it matches?

You could make a new Blueprint and have its’ parent be the Blueprint you’re using now to play the sound. Then set the new Blueprint you made to be the class type you select in the “Get All Actors Of Class”, and then replace the actors in the world that you want deleted/deactivated with the appropriate new Blueprint type.