One of my apps have recently failed certification because: "my app stops background music without asking user when it wants to play some music".
Now the question is: how can we detect if there is any music playing in the background?
Regards
  using Microsoft.Xna.Framework.Media;
...
    if (Microsoft.Xna.Framework.Media.MediaPlayer.State == MediaState.Playing)
    {
          ....
    }
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With