Copy link to clipboard
Copied
I got a suggestion from a customer concerning my Android app. When you exit the app, it continues to play in the background (unlike iOS). I would like to add functionality to the app (game) to pause (suspend) on exit. I tried some different coding version with out luck. The Android tablet (and phones) I test it on ignores the code and the games timer continues to tick down. I'm using Flash Pro CC with AS3. Not sure what the problem could be at this point!
Copy link to clipboard
Copied
In your case if you want just pause its add event listener fir app deactivate and activate and start and stop your timers also set stage framerate to 1
Copy link to clipboard
Copied
Your app would get rejected in some stores, certainly the Samsung one. The basics are that you have deactivate and activate listeners, and those need to pause your game. For some of my apps all I need to do is make the sound volume be zero, then on activate I set the volume back to what it was before. If you have more complex game play you would want to have a pause button anyway, and the deactivate event would just call the same routines that the pause buttons uses.