I got this file that very simply, plays a wav file.
Now I want to be able to set a boolean value mute to true.
Then the file should stop playing the wav until mute = true again.
But I dont want a while loop looping every second, because It would lag my game too much.
So how can I do it without using while?