Jump to content

Game not rescaling after game.stage.scale.stopFullScreen() on Firefox


jdiego82
 Share

Recommended Posts

I used some code I found around the forums for scaling my game to fit exactly in the screen.

game.stage.scale.pageAlignHorizontally = true;game.stage.scaleMode = Phaser.StageScaleMode.EXACT_FIT;if (game.device.desktop){   game.stage.scale.setShowAll();   game.stage.scale.refresh();}else{   game.stage.scale.forceLandscape = true;   game.stage.scale.setScreenSize(true);}

It works in all of my browsers (Chrome, Firefox, IE 11, Opera, Firefox for Android) and going in and out of full screen mode in Chrome is fine, but when going out of fullscreen in Firefox, the game doesn't rescale properly.

 

Can anyone give me some code that would work for scaling across desktop and mobile browsers, as well as for proper rescaling when going in and out of fullscreen mode on desktop browsers?

Link to comment
Share on other sites

 Share

  • Recently Browsing   0 members

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