A few questions about exporters

Discussion and feedback on Construct 2

Post » Tue Oct 21, 2014 10:45 am

Hi Everyone,

In the last few weeks, I tried very hard to export my project to both Android and iOS with very mitigated success. I've encountered many problems that I didn't see referenced anywhere on this site/forum. Some of them are really hard to deal with, and most of them are probably due to the size of my project.

However I never heard anyone saying that it could be problematic to export big projects with Construct 2. Well, from what I've experimented so far, it is. Here are the main problems :

1) Phonegap Build upload is limited to 40 Mb maximum zip files. This is not referenced in the official "How to export to mobile with Phonegap" tutorial. When I first encountered this problem, my project was already 50Mb heavy, and far from being finished. Now after 2 weeks of optimizations I'm under the 40Mb limit, but I still have to add graphics in my game, so the struggle is not over. Is there any workaround with this issue?

2) At the moment, an Intel XDK bug makes Crosswalk export on Android bug if they contain more than 250 images... Well... 250 images is what some people on the project told here :
(remove the _ in the link)
https_://crosswalk-project.org/jira/browse/XWALK-2655 (delete "_" as I'm not able to post links)
But at the moment I reduced the number of image in my project from 270 to less than 220, and the bug is still here. What I call "the bug" is the app crashing as soon as the game begin, so it can't be published. I know from @IntelRobert that the staff is actively working on this problem, but if it's not fixed very soon I will be unable to publish to android via XDK.

3) The loading time of th APK of my project exported with XDK/Crosswalk is also very problematic. Here is how my game launches :
- My custom splash screen for about 2 seconds.
- A completely black screen for about 30 seconds ! (most users will be gone)
- The Construct 2 default loading screen (little blue bar) for about 5/10 seconds
- THEN, finally, my (very light) customized loading screen for about 2 seconds (!!!!!!!)
This loading time seems to repeat itself each time I start the APK, not only the first time.

For reference, the Android export has been tested on a Samsung Galaxy Tab 3, 7"

Thanks in advance for any help/comment/advice !
B
32
S
6
G
1
Posts: 352
Reputation: 2,810

Post » Tue Oct 21, 2014 11:39 am

The phonegap build has this limitation, but building offline does not impose this (however, how to do this is out of my knowledge, maybe just building a cordova app with the XDK?)

For 3, I wonder, does changing the "preload sounds" in the project prorieties changes that?
https://www.scirra.com/manual/66/projects
Game design is all about decomposing the core of your game so it becomes simple instructions.
B
53
S
22
G
18
Posts: 2,122
Reputation: 17,123

Post » Tue Oct 21, 2014 1:14 pm

1) Yes, you can build locally using the PhoneGap CLI. This is not officially supported yet, but I think we will add support at some point, since it allows for any size build and also circumvents the subscription for PhoneGap Build, but it's a lot more complicated. You should be able to choose a normal PhoneGap export from C2 and then follow existing PhoneGap documentation on how to build it offline.

2) Looking at your link, the issue is already marked as 'fixed'. Hopefully it's only a matter of time for this to come through to the stable build, but you could possibly get the fix earlier by choosing the beta version of Crosswalk. (You'd need to check exactly which versions the XDK is using.)

3) All it has to do to show the C2 loading screen is load the html and parse c2runtime.js, so that should be no more than a second or two's work, so a 30 second wait is definitely suspicious. If you've got Chrome's inspect tab up then maybe that time is spent trying to establish a connection? I don't know what it could be doing for that time, but I haven't heard of such a long delay before even the C2 loading bar appears before. Note currently on Android Chrome (and Crosswalk, consider them the same thing) is slow at decoding audio which can add to the loading time if 'Preload sounds' is on, so it may be worth turning it off and seeing if that helps. The linked bug report shows that Google are aware of that particular issue though so it may be fixed in future as well.
Scirra Founder
B
397
S
236
G
88
Posts: 24,389
Reputation: 194,448

Post » Tue Oct 21, 2014 2:31 pm

Thanks a lot, Ashley and Aphrodite.
Seems like the problems have or will have a solution, which is reassuring.

1) I'll dig deeper into this offline Phonegap build. Glad there is a workaround.
2) I builded the project yesterday evening and the APK was still crashing. But it's true it was through "stable" XDK and I didn't look for the Crosswalk version. I'll check these.
3) Indeed, I have audio preloading activated, I'll try switching it off. But aren't the sounds preloaded during the preload screen? If not, setting the preload option to "No" and preloading the sounds manually during the loading screen could do the job, right?
B
32
S
6
G
1
Posts: 352
Reputation: 2,810

Post » Wed Oct 22, 2014 7:15 pm

@Rable - i was having the same number #3 issue, with the black screen, aprox 30 seconds or even more, the workaround that i found was to set "Use loader layout" to No, "Preload Sounds" No, and i have build it with beta in crosswalk, and it looks like it work fine now. Im testing in a nexus 4, i will test it in other phones soon.

Pls, if you found any solution to work with a custom loading screen, post it!

cheers!
B
9
S
2
Posts: 52
Reputation: 1,360

Post » Thu Oct 23, 2014 4:06 am

@Rable maybe you have imported music as sound? thats what i did to geat arround the issue, that you cant controll volume of music in crosswalk, and that was when i had so horrific loading times...

regards
B
19
S
7
G
1
Posts: 222
Reputation: 2,546

Post » Thu Oct 23, 2014 10:49 am

I tried this morning to set "preload sounds" to "no", and it doesn't quite fix the thing. It's maybe a bit better though, but I still have the long black screen.

@6bruno6
Thanks for the tip. I never tried setting "loader layout" to "no" up to now, but my loader layout is quite light : one animated sprite with the loading bar on a white screen. I hardly see how it could take many time to load, but I'll try it anyway.

@j0schi
Indeed, I load the music of my title screen as a sound, in order to be able to preload it, and launch it as soon as the title screen is visible. I was hoping that it would load during the loader layout, but I'll try to put it back to the music folder.

I'll post the results of my tests here, and share any improvements on the loading times.
Thanks !
B
32
S
6
G
1
Posts: 352
Reputation: 2,810

Post » Thu Oct 23, 2014 2:45 pm

If i remember right Ashyley mentioned it somewhere, that android is currently very slow with decoding. so if you put it in the soundfolder it gets decoded on start rather than on the fly... i would also prefer that everything is preloaded, also because the volume controll then works for me, but that is just not possible at the moment. 20 minutes of music took my s2 3-5min to start the app haha

regards
B
19
S
7
G
1
Posts: 222
Reputation: 2,546

Post » Fri Oct 24, 2014 8:45 pm

So !
I did the following :
1) Remove the music form the sound Folder and put it back in music.
2) Put "Preload sounds" to no
3) Put "use loader layout" to "no" and put my title screen as the first layout (instead of the loader layout)
4) Build using XDK Beta version instead of stable

And I didn't notice much amelioration... :(
Loading the game for the first time I had :
- 6 seconds black screen
- Splash screen during 2 seconds
- 30 seconds black screen
- 3 seconds default loading bar

When starting the game again I had :
- 2 seconds splash screen
- 22 seconds black screen

My game is still crashing, but I'm now able to play 5/6 level before it crashes.

I'm unable to use the inspect tab of google at the moment, but I doubt there is any connection going on. My game doesn't ask such things and I'm using mostly default options in XDK.
B
32
S
6
G
1
Posts: 352
Reputation: 2,810

Post » Mon Jun 22, 2015 4:51 pm

Hi @Rable how are you? I wondered if you could solving your old problem with the black screen and and everything else. Actually I'm about to publish a game on Android with various (50-60)mb of music and graphics, and I have a bit afraid about that... I would like to know if is possible avoid that horrible black screen, if not how you said most users will be gone. :(

Shimo.
B
14
S
4
G
2
Posts: 109
Reputation: 2,679

Next

Return to Construct 2 General

Who is online

Users browsing this forum: No registered users and 9 guests