totallybueno Posted August 25, 2017 Share Posted August 25, 2017 Hi there, I have a "more o less basic" game and now that is almost finished, I realized that the performance on iOS is ridiculously bad. Running the game on old Android devices I get easyly 60 fps, everything runs smoothly, but the same game, running on an iPhone 7 (and obviusly on older devices) it´s gettting 15 fps, being and easy game on a much more powerfull device (good one, Apple). The thing is, I read that maybe tilesprites (I´m using one) could "help" to this poor performance, but this is not the case, even without that tilesprite I´m still getting 15 fps... Can anyone point to things to check? Stuff that affects only iOS? I´m not finding how to fix this... Link to comment Share on other sites More sharing options...
totor Posted August 25, 2017 Share Posted August 25, 2017 unless you provide a working sample of your test case it will be difficult to guess the problem, especially if it works smooth on old android and slow on iphone 7 which is pretty high end. Maybe check the Phaser.CANVAS tag when you create the game. Link to comment Share on other sites More sharing options...
totallybueno Posted August 28, 2017 Author Share Posted August 28, 2017 (edited) I just uploaded a demo to http://totallybueno.com/demo/falling/ When I create the game, that tag is Phaser.AUTO, I tried with Phaser.WEBGL too but I have the same result... so fustrating... And it seems with Phaser.CANVAS that performance is really good, thanks for the tip @totor. I´m just curious, if someone can explain here why this happens, would be really nice... anyway, it´s working Edited August 28, 2017 by totallybueno Link to comment Share on other sites More sharing options...
samid737 Posted August 28, 2017 Share Posted August 28, 2017 Tested on my iphone 5c, works flawless..... 98-99 draw calls looking at the canvas debugger in firefox (windows): Should not be required for this type of mobile game... you can try to fit all the seperate images into a single atlas. totallybueno 1 Link to comment Share on other sites More sharing options...
samme Posted August 28, 2017 Share Posted August 28, 2017 Also, for many of the world objects (mushrooms?) you should be able to do something like this: var top = this.camera.view.top; var bottom = this.camera.view.bottom; manyObjects.forEach(function (obj) { obj.renderable = (obj.bottom > top) && (obj.top < bottom); }); dude78 and totallybueno 2 Link to comment Share on other sites More sharing options...
totallybueno Posted August 29, 2017 Author Share Posted August 29, 2017 I guess if they´re not renderable I´ll have less cpu/ram needed, right? Thanks for the tip @samme Link to comment Share on other sites More sharing options...
Alex2134 Posted November 9, 2018 Share Posted November 9, 2018 @totallybueno Wich programs do you use to check the (Cpu/Fps) on real devices? I have been looking for a long time and I couldn't find any, can you guys recommend me any? I can't believe that tools like this which are the most important thing don't exist for smartphones, at last on ios there are none Thank you and sorry to hijack this thread Link to comment Share on other sites More sharing options...
Recommended Posts