ANR rate up for anyone else on Android?

0 favourites
  • Thank you for creating the report.

    I'll hope our creators find the problem.

  • fredriksthlm So on github you emphasized that GMA SDK version has to be 21+, from which I assume that the one used by default is not? How can I use 21.2.0, is it as simple as adding this line of code in build.gradle

    implementation 'com.google.android.gms:play-services-ads:21.2.0'

    So it looks like this:

    dependencies {

    implementation "androidx.appcompat:appcompat:${cordovaConfig.ANDROIDX_APP_COMPAT_VERSION}"

    implementation "androidx.webkit:webkit:${cordovaConfig.ANDROIDX_WEBKIT_VERSION}"

    implementation "androidx.core:core-splashscreen:${cordovaConfig.ANDROIDX_CORE_SPLASHSCREEN_VERSION}"

    implementation 'com.google.android.gms:play-services-ads:21.2.0'}

    Or is there more to it?

  • I believe it is easier for you to just use the menu.

    File>Project Structure>Dependencies

    and check the app module. there you can manually define the versions. when you press OK the project will resync and update the libraries

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Ok, thanks a lot, I'll try this in my next update :)

  • Any updates/findings regarding this issue?

  • Unfortunately, the fix suggested by fredriksthlm didn't change anything for me.

    I found out that ANRs started with release r303 (and every release after that) and it probably has nothing to do with the updated Advert Mobile plugin, because it was only updated in r306.

    Right now I'm checking my other theory - whether this is caused by changes with Splash screen (Scirra changed splash screen plugin in r303). I've built my game in r314, disabled the new splash screen and released this version today. In the next couple of days I'll see if this solves the problem.

  • Do you use billing/IAP?

    (The currently used splashscreen is a native google/android library)

  • fredriksthlm Hello.

    I use billing/IAP.

    I noticed that sdk 3.0.3 works well and is stable. But alas, it is old and Google requires it to be updated.

    I tested 4.0.0 but it shows more ANR.

  • igortyhon did you test with the same Construct version but different billing libraries? If you did, and you noticed the difference - it could be the cause. But if you tested in different C3 versions - them having different billing libraries could've just been a coincidence.

  • fredriksthlm I do use billing, but r303 uses older version 3.0.3, yet I didn't see any difference in ANR rate between r303 and r307. I've released a version with splash screen disabled yesterday with r314, and there are 0 ANRs so far. It's still a bit early to draw conclusions, but usually there would have been ANRs by now (judging from my previous updates)

  • Simple Games No.

    R302 - Billing 3.0.3

    R308.2 - Billing 4.0.0

    Therefore, it is difficult to draw conclusions.

    I will try the R314 version.

  • I fixed this by commenting out cordovaInterface.pluginManager.postMessage("setupSplashScreen", splashScreen);

    in CordovaActivity.java in Android Studio project. It fixes the ANRs and Slow cold starts by disabling the new Splash screen that has been introduced in r303. But then you have a few seconds of black screen instead of the splash. So until this is fixed, the best option is to keep using r302 or earlier version of Construct, this way you won't be getting the ANRs and will keep the splash screen.

  • FWIW, the handling of the splash screen is part of Cordova, not Construct.

  • Ashley Maybe you can't fix the new splash screen, but you could revert to the old version, right?

  • This thread is duplicating the discussion in the corresponding GitHub issue where I already responded to that question.

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