Jump to content

Remove Any Phaser Process when Visibility Hidden

Recommended Posts

Hi there,

Just a little background info. I try to submit my HTML5 games for TIzen smartwatch.
After some review process, my games got rejected because they detected that my games still using 12~24mA electricity when screen off/sleeping. Any application/games shouldn't be above 4~7mA when the device is sleeping, so they assume there is problem with my games when sleep/wake up.

I'm not using any special code from phaser regarding visibility change, I left all of them at default.
Is there any way to make sure that Phaser doesn't process ANYTHING at all when the screen is hidden (because screen off/sleeping)? I need to change the source code maybe?


Link to post
Share on other sites


From reading source code, I realize the main controller of game loop is the game.raf . I assume that by stopping game.raf, I will totally stop any Phaser internal game process, is that right?
Can I safely call game.raf.stop() and game.raf.start() when I detect screen change?

Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recently Browsing   0 members

    No registered users viewing this page.

  • Create New...