Jump to content

Phaser Ignores Scaling Completely


MishaShapo
 Share

Recommended Posts

I've been trying to achieve the effect that this.scale.scaleMode = Phaser.ScaleManager.SHOW_ALL is supposed to achieve, but it seems that changing the scale mode has no effect.

 

Here is my Boot.js

        this.game.input.maxPointers = 1;        this.game.stage.disableVisibilityChange = true;        this.scale.scaleMode = Phaser.ScaleManager.SHOW_ALL;        this.scale.setMinMax(360,480,560,960);        this.scale.setGameSize(560,960);        this.scale.windowContraints = {"right":"layout","bottom":"layout"};        this.stage.forcePortrait = true;               this.game.scale.pageAlignHorizontally = true;        this.game.scale.pageAlignVertically = true;        this.game.scale.forceOrientation(false, true);	               this.game.scale.updateLayout(true);        this.game.input.addPointer();               this.game.stage.backgroundColor = '#171642';        this.game.stage.width = 560;        this.game.stage.height = 960;        this.game.scale.refresh();

But my images are still stretched. As you can see, there is an inline styled with dimensions that exceed the ones set in Boot.js

 

Ideally, I would want it to look like the second image, centered with background padding on the sides in case the window exceeds the min/max dimensions.

 

 

 

I have no idea what to do. And any and all help is very appreciated.  :(

post-14971-0-72694400-1448516172_thumb.p

post-14971-0-35758200-1448516460.png

Link to comment
Share on other sites

 Share

  • Recently Browsing   0 members

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