Cordova stuttering on Android

Post » Sun Jun 04, 2017 2:09 pm

martdsam wrote:Will exporting to older versions of Android (4.4) be implemented? Exporting only to 5.0 or higher, the game achieves only half of the devices it should reach.

No, but Android 5.0+ already covers over 70% of devices. See this thread.
Scirra Founder
B
395
S
231
G
88
Posts: 24,367
Reputation: 193,684

Post » Sun Jun 04, 2017 2:19 pm

Ashley wrote:
martdsam wrote:Will exporting to older versions of Android (4.4) be implemented? Exporting only to 5.0 or higher, the game achieves only half of the devices it should reach.

No, but Android 5.0+ already covers over 70% of devices. See this thread.


I do not know if 70%. Well on googleplay the devices that bring my game down by half after I upload a compiled version in construct 3. But you're right to think about the future, I suspected that was the reason to use it only for versions above 5.0.

Thanks for the answer. :)

If it's not uncomfortable. I need some help with this problem. I can not find a solution.
https://www.scirra.com/forum/error-after-publishing-my-game-on-googleplay_t192381

I spent all day yesterday learning how to sign an apk manually. And after a lot of work, I finally learned how to do it. But now this problem is preventing my game from working normally. Thank you :)
Hi I am Samuel :)

My google play
B
42
S
10
G
1
Posts: 126
Reputation: 3,278

Post » Mon Jun 05, 2017 1:23 pm

@rhg1968 Cordova doesn't support platform specific plugins, at least not through config.xml, and iOS requires a few boilerplate ones hence why things like wkwebview are appearing in android. If you request a build with no iOS target from the build server you will only get the android requirements ( which should basically be nothing, unless you have plugins that need cordova plugins ).
Scirra Employee
B
5
S
2
Posts: 125
Reputation: 873

Post » Mon Jun 05, 2017 5:35 pm

I did as you mentioned and if I don't include the ios version so that the wkwebview plugin is not included, the android now runs smoothly.

There is definitely something with the wkwebview for android that causes the issue, but removing the plugin for android definitely works, which can be done command line also if you download the files even if the ios version is included in the build.
Last edited by rhg1968 on Tue Jun 06, 2017 12:27 pm, edited 2 times in total.
B
16
S
8
G
6
Posts: 27
Reputation: 4,354

Post » Tue Jun 06, 2017 11:03 am

@rhg1968 We're pretty sure one of the iOS required plugins is causing the problem for Android.

The issue with defining plugins for separate platforms comes from the way cordova parses it's config.xml file, as it will only download plugins for the whole project not individual platforms.

We generate this file in the first stage of the cordova export, hence if you specify iOS and Android versions in the first prompt you end up with all the plugins. The second prompt tells the build server which builds you would like, and for consistency the server does what cordova does and installs all the plugins for both.

It's a bit awkward that we could make the server smarter, but people taking the cordova project instead would get different results.

As we can't modify the way cordova behaves the solution we've come up with is to split the cordova exporter into 2 separate ones: iOS and Android.
Scirra Employee
B
5
S
2
Posts: 125
Reputation: 873

Post » Tue Jun 06, 2017 12:22 pm

@Nepeo I appreciate all of your feed back. I totally understand the quirks of cordova projects as I develop a lot of cordova mobile apps for my employer. It's just nice for everyone to discuss these issues and how to best work around them. I'm sure it's difficult trying to develop a generic build service that will work for everyone, but what you have made so far is impressive and build very quickly.

I am just starting my first game in C3, I have developed one other game and released using libgdx, but so far the ease of use of C3 is awesome and much more productive.

I guess in a long round about way I'm trying to say keep up the great work :D
B
16
S
8
G
6
Posts: 27
Reputation: 4,354

Post » Thu Jun 08, 2017 9:11 pm

Unfortunately the stutterings is not gone for me on my Samsung Galaxy S5 Neo, even with the new Cordova exporter. I decided to update my performance measuring for my Tappy Plane app, what I'm doing now is counting the length of every delta time and then showing how many ticks took place in certain delta time intervals. After playing for about 1.5 minutes each on the Cordova exported app and the web exporter running on my server, these are the values I got for the delta time values. Note that it feels smooth when running in Chrome but "mostly smooth with frequent stuttering" using the cordova app.

Samsung Galaxy S5 Neo
Cordova
  • 0 - 20 ms: 90 %
  • 20 - 40 ms: 8.5 %
  • 40 - 60 ms: 1.2 %
  • 60+ ms: 0.3 %
Chrome
  • 0 - 20 ms: 99.5 %
  • 20 - 40 ms: 0.4 %
  • 40 - 60 ms: 0 %
  • 60+ ms: 0.1 %


I thought that maybe it's just my device that is not powerful enough, so I tried both versions on my wife's Galaxy S4. These are the values on her phone, both the web export and cordova app felt smoothw when playing.

Samsung Galaxy S4
Cordova
  • 0 - 20 ms: 98.2 %
  • 20 - 40 ms: 1.6 %
  • 40 - 60 ms: 0.1 %
  • 60+ ms: 0.1 %
Chrome
  • 0 - 20 ms: 99.5 %
  • 20 - 40 ms: 0.3 %
  • 40 - 60 ms: 0.1 %
  • 60+ ms: 0.1 %


Note that even though Cordova performance was smooth on her S4 it still performed a little worse than the version running in Chrome even though I couldn't have told them apart without the measurements. Are the stutters gone for everyone else since the Cordova exporter got split into two?
B
10
S
1
Posts: 13
Reputation: 481

Post » Fri Jun 09, 2017 12:14 pm

@Ultimadark we have had a couple of reports of "laggy" behaviour still, thanks for confirming them with some hard numbers! I'm going to have a look through the process, just to make sure the plugins are definitely not being added. If not... well it's going to require some profiling!
Scirra Employee
B
5
S
2
Posts: 125
Reputation: 873

Post » Tue Jun 13, 2017 8:56 pm

Add me to the stuttering app problem with C3. I'm using an LG Stylo android device running Android 6.0

The game does play fine in chrome on the device.. like solid fps.. http://part12studios.com/temp/Games/soaring/ (note this is an older version but you get the idea)

I'm "glad" to see it's not just my device doing this. I bought this phone recently just to have a newer android device to test with.. only to see it's misbehaving.. that said this phone plays other games fine I refuse to accept that this is just some edge case phone and i need to buy another phone to test successfully...
B
59
S
9
G
1
Posts: 939
Reputation: 6,545

Post » Wed Jun 14, 2017 7:07 pm

Testing my old https://play.google.com/store/search?q=buildpunkt&hl=en games (CocoonJS) with an S8 most delay problems have been fixed except audio delays.
B
16
S
3
Posts: 115
Reputation: 2,428

Previous

Return to General Discussion

Who is online

Users browsing this forum: Solomon and 0 guests