Just a quick question.
I want to cause a kind of deafness or muffled audio in my game, like what has been heard in a few other games out there, particularly the Battlefield games when you’ve lost a lot of health, or there is an explosion nearby (example below of muffled audio bugged out).
Another game would be ARK, when your character gets severely injured.
I understand how to change the LPF in an existing sound source, I understand how sound volumes work too. But what I want to know is how to muffle ALL audio sources if a player were to have an explosion go off nearby and cause temporary deafness that would slowly fade back out (LPF value increases so audio returns to normal), how would I go about adding LPF to an entire sound class, like the Master sound class? Is this even possible? Or would I need to get that sound class, then iterate through every sound containing that sound class and override the attenuation settings? (seems a very expensive way to do it).
I have some C++ knowledge, so I’m happy to do it within C++ (It is most likely where the magic would happen I would imagine).
I thought maybe I could dynamically just add an audio volume to the characters head and change the Outside LPF to something insanely low and Inside LPF to something pretty low, and add reverb as well, but it seems impossible to add an audio volume to a character, I can’t even create the volume in the level at run-time and attach it to the character, so I’m at a loss with that work-around.
Any advice or suggestions would be great!
Thank you in advance