Jump to content

HEADLESS mode (MultiPlayer game)


darkj3ean
 Share

Recommended Posts

Hi I am building a WebRTC multiplayer game. I want to use the HEADLESS mode but it doesn't seem to work? i set rendering  to HEADLESS but it still renders. How do you actually use it?

Also, is there a solution to not stop the update loop when tab change or window is minimized?

If your curious to what I'm doing, here is my progress so far: 

 

Link to comment
Share on other sites

  • 1 month later...

I've always been curious about headless mode. I use quite a lot of client side information but still have a fully functional multiplayer game. Its turn based though which makes it much easier.

To fix the issue with the game pausing when tabs change etc... the only option I know of is http://phaser.io/docs/2.4.7/Phaser.Stage.html#disableVisibilityChange but it still can pause, for me it happens if I minimize the browser.

Link to comment
Share on other sites

The update loop pausing when you switch tabs/minimize, etc is a result of Chrome (and other browser) memory management. I'm afraid there's not a workaround that I know of. DisableVisibilityChange does work partially - i.e. if you minimize, it will still resume or if you click another tab or vice versa (forgot which). But I'm pretty sure disableVisibilityChange is not a guarantee for what you want to accomplish (always have the game run regardless of the window state). 

Link to comment
Share on other sites

 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...