haden Posted May 2, 2016 Share Posted May 2, 2016 Trying the following example: http://phaser.io/examples/v2/input/game-scale I see the following error message in the console: embed.php:43 Uncaught TypeError: game.scale.setScreenSize is not a function I guess this function was removed in a recent version of Phaser. Any idea how to get the example working ? Link to comment Share on other sites More sharing options...
game-dev-monkey Posted May 2, 2016 Share Posted May 2, 2016 I believe that was deprecated at some point, check out http://phaser.io/docs/2.4.7/Phaser.ScaleManager.html#setGameSize Link to comment Share on other sites More sharing options...
shpowley Posted May 3, 2016 Share Posted May 3, 2016 I filed this issue in github - https://github.com/photonstorm/phaser/issues/2458 [Phaser 2.4.7 | tested 5/3/2016]: With this particular example, I think you can make code corrections to make this work in your own dev environment. - var game = new Phaser.Game(320, 240, Phaser.CANVAS, 'phaser-example', ...replace phaser-example with null - Replace the line "game.scale.setScreenSize();" with "game.scale.refresh();" Going through this website interface, even with the changes, the file "phaser.2.4.7.min.js" doesn't load for some reason. But that's a different issue as we don't have as much control on the server-side. Link to comment Share on other sites More sharing options...
haden Posted May 5, 2016 Author Share Posted May 5, 2016 Thanks Link to comment Share on other sites More sharing options...
vohogames Posted July 9, 2016 Share Posted July 9, 2016 I have the same problem. in 2.1.3 version this.scale.scaleMode = Phaser.ScaleManager.EXACT_FIT; this.scale.setScreenSize(true); Now, i am trying to use latest 2.6.0 and this.game.scale.refresh(); doesnt work as expected. Any solution? -- solution removed html div id tag as explained above Link to comment Share on other sites More sharing options...
MarvinB Posted July 10, 2016 Share Posted July 10, 2016 For the set screen size error, try this: Phaser.ScaleManager.prototype.setScreenSize = Phaser.ScaleManager.prototype.updateLayout; Link to comment Share on other sites More sharing options...
vohogames Posted November 23, 2016 Share Posted November 23, 2016 I wıll try ıt, thank you. update: tried and it seems it didnt work. There is something with the behaviour of samsung note5 default browser. It works a bit different than a normal ( like samsung s4 ) browser Link to comment Share on other sites More sharing options...
Recommended Posts