Slowdown with Phonegap build - works fine on mobile browsers

0 favourites
  • 7 posts
From the Asset Store
a ready made template of Mobile Advert, Google Play and Mobile IAP Plugin,
  • Hi everyone,

    I'm trying to export a game using Cordova and then build it with PhoneGap Build for Android.

    On Chrome and Firefox for Android, the game works nice, more than 50 FPS all the time.

    I also tested it through this app : https://play.google.com/store/apps/deta ... view&hl=en

    and it works nice too.

    However, when built with Phonegap Build the FPS fall to 30, so the game seems pretty laggy...

    I also remember building this app like 4 months ago, still through PhoneGap Build and it used to work like a charm.

    Also, the Construct 2 "renderer" expression always returns "webgl" whatever the method is (on browser, with the HTML5test app and after PhoneGap Build).

    This is probably not C2-related, but could there be any solution to this annoying problem? Maybe a Cordova update which broke something?

    Thanks in advance.

  • are you using physics in your game? the latest C2 patched a memory leak in the physics engine which would cause slow-down.

  • I'm not using physics at all... Besides, that wouldn't explain why the game works nice on mobile browsers and not on Phonegap.

  • We suspect that some older Android devices have WebGL blacklisted in the webview only (i.e. Cordova apps). We're currently working with Google to try to work around this.

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • Hi Ashley, thanks for answering this.

    However the devices we're testing the game on are pretty recent (a Samsung Galaxy A3 2017, for instance, not the best Android phone out there but released just one year ago...). In addition, as told before the "renderer" expression from C2 still returns "webgl" when tested through Phonegap, and the HTML5test app runs the game fine, while using a webview...

    I also tested exporting the game in C2 targeting Android 4+ using Crosswalk and the frame rate seemed slightly better (~40 FPS instead of ~30).

  • I've started to inject Cordova in all my APKs that are pre Android 7 (in which Chrome browser itself becomes the actual WebView). APK size grows a bit, but there are just too many non-premium models out there with outdated WebViews or blacklisted WebGL drivers. Cordova is deprecated but even with the Chromium version is based on, it's better enough than many native webviews in not so old phones.

  • '"I've started to inject Cordova in all my APKs that are pre Android 7"

    That's interesting, but did you mean Crosswalk instead of Cordova there?

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)