I’m making a game for iOS and I added music playing in the background in two scenes. I built the game with Xcode and Cordova to test on the iPhone but, whenever I exit the app leaving it in the recent apps and I reopen it, the music doesn’t resume.
I have two scenes with this event.
UPDATE: I tried it on the iPhone simulator of Xcode and it works, I don’t know why it doesn’t on a real phone. If it helps I have a 15 Pro Max.
IPhones do not support wav files (according to my google search), try an aac format instead.
(The first result says it can not, the other results says it can) So it might help to try the aac
That’s not the problem. I tried with WAV, MP3, OGG and AAC.
The audio plays just fine with all those formats, the issue is that when I exit the game and leave it in the background, after I reopen it the audio stops playing and doesn’t restart even when changing scene.
Did you try playing in channel? or Playing as Music?
The same thing happens when using
Play Sound in a Channel or
Play a Music File.