0

I have provided mute functionality in my game. But if music player is running in background and when I start my game in normal mode (not in silent mode) music player is not getting paused

I have used [[SimpleAudioEngine sharedEngine] stopBackgroundMusic]; to stop background music and playing my game music using
[[SimpleAudioEngine sharedEngine] playBackgroundMusic:audiofilename loop:YES];

What should I do ?

Guru
  • 21,652
  • 10
  • 63
  • 102
parikhnirav
  • 33
  • 1
  • 7

1 Answers1

0

There is method of pauseBackgroundMusic and resumeBackgroundMusic in SimpleAudioEngine class.. So try these methods instead of stop and play everytime. Hope this helps.. :)

Nikhil Aneja
  • 1,259
  • 8
  • 13