iOS audio is sometimes silent after resuming

Our game has a serious issue with the audio sometimes just not coming back after resuming the app. This happens sporadically, but we can recreate it fairly consistently (nearly 50% of the time) by doing these steps:

  • Run the game
  • Press home button to put the app in the bg
  • As soon as springboard appears, press power button to lock device
  • Press home button right away
  • Unlock device
  • Tap game icon as soon as it appears

Some of our beta testers have encountered the same issue. We’ve narrowed it down to being some kind of bug with Unity’s audio handling. So first, I’m wondering if there’s some special fix for this out there?

The other thing is I’m wondering if there is some way of manually resetting Unity’s audio session from Obj-C when the game resumes, to kind of force it to restart and not break.

I think this issue is probably related to this: http://forum.unity3d.com/threads/202362-Sound-issues-when-coming-back-form-background but there hasn’t been any progress there in months.

Thanks!

-Matt

The following method has C bindings:

Here is a similar thread. Not sure if it’s the same issue.

http://forum.unity3d.com/threads/202362-Sound-issues-when-coming-back-form-background