Jump to content

How is game.resolution supposed to work?


Recommended Posts

  • 1 month later...

That looks like a bug to me and happens with < 1.0 resolutions as well.

@samme Why do you want to use a resolution greater than 1.0? I can't see any point going above that scale because you're not taking advantage of the whole canvas.

On the other hand, 0.5 = each sprite pixel takes 4 screen pixels and so forth. This runs a lot faster on the GPU and is how I can get my game to run at 60fps on devices with slower graphics cards :-)

Something cool I found: You can dynamically change the resolution without reloading the game by directly modifying this._game.renderer.resolution (reading the docs of Phaser.Game says it's read only and can only be set via the configuration object, see https://github.com/photonstorm/phaser/commit/74eeddf956963bff2b1b03a8ab5b7563d25cb818)

Edit: More info here https://github.com/photonstorm/phaser/issues/2946

Link to comment
Share on other sites


  • Recently Browsing   0 members

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