Jump to content

resolution on devices


scofieldly
 Share

Recommended Posts

hi all, 

currently I got a question about new Game() constructor

as the define, the width and height are pixels.

e.g.

The width of your game in game pixels. If given as a string the value must be between 0 and 100 and will be used as the percentage width of the parent container, or the browser window if no parent is given.

but when I use iphone 5s (1136 pixel width, 568 pt width) to create a 640 width game, it can not display fully, it looks that only 568 display in the screen.

 

so I want to know how to understand this situation, thanks.

 

Link to comment
Share on other sites

Phaser has a few built in scaling modes that place and scale your desired size canvas in the browser window.  If you are using one of these modes, then I'd guess something isn't quite right in your code. Maybe start by stripping your html div right down to the basics, a lot depends on the div, then look at your scaling setup.  Refer to the scaling examples for guidance.

Link to comment
Share on other sites

 Share

  • Recently Browsing   0 members

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