What is happening at runtime?

Discussion and feedback on Construct 2

Post » Fri Nov 01, 2013 10:44 am

I've created a game that uses lots of pretty big png-sequences and it has 4 different levels. One of the layout uses sounds aswell.

The wierd thing is that it runs really slow on my ipad the first minute or so and when looking at the profiler it seems that it is the "draw calls" that are taking up more than 100% of the processor. BUT when I've switched between the levels it suddenly runs smooth. What is happening here? Caching of the bitmaps? I should mention that I have about 10 mb of images in total.

* So if there is some caching going on, is it possible for me to wait for all this to finish before allowing the user to enter the game?

* Can it be the sound that stalls the rendering? I have noticed that the layout with sounds leads to most of the problems, sometimes it also crashes safari on ios and also the cocoon tester..

* I also experince problems with big delays when switching layouts, what is happening behing the curtains? Isn't it already loaded?

Thank you!
B
7
S
1
Posts: 22
Reputation: 526

Post » Fri Nov 01, 2013 12:07 pm

Construct 2 pre-loads each layout's textures before loading it, so there should be little to no dynamic loading or caching during the game. Which device model and OS version are you testing on?
Scirra Founder
B
398
S
236
G
88
Posts: 24,433
Reputation: 194,635

Post » Mon Nov 04, 2013 8:21 am

I'm testing on ipad2 with ios7.

One really strange thing is that when I am testing on LAN preview, the game tuns fine, but when I deploy to my server and test it drops down in framerate and becomes unresponsive. Since everything loads fine it seems that something seems to happen in runtime and it does not get better with time.

Can it be some settings on the server? Or how is LAN-preview different from running from a external server?

* I have a really good connection to the server so that should not be the problem
* The mime types are correct on the server

I have noticed the same issue when testing on cocoon launcher, it works when entering the preview server but when I enter the URL to the external server it does not even load sometimes, and if it loads I have the same issues with really low frame rates and occasional crashes.

Any ideas?
B
7
S
1
Posts: 22
Reputation: 526

Post » Mon Nov 04, 2013 3:07 pm

Usually it needs 10-20sec to "warm up" (it'll be compiling the javascript dynamically), then it's a lot smoother. How long are you giving it?
Scirra Founder
B
398
S
236
G
88
Posts: 24,433
Reputation: 194,635

Post » Tue Nov 05, 2013 12:51 am

so far there's no solution to this since the CPU is doing the rendering, unless there'd be some way to add a hack for Safari browsers to the export to lower draw calls.
B
12
S
3
G
1
Posts: 347
Reputation: 2,866

Post » Tue Nov 05, 2013 7:37 am

Well i have noticed that but sometimes it never warm up. Is there any way to listen for this warm up finished? Any event or callback?

And also, why is the performance different when running lan preview versus external server? This should not affect the fps or the warm up time?
B
7
S
1
Posts: 22
Reputation: 526


Return to Construct 2 General

Who is online

Users browsing this forum: Yahoo [Bot] and 18 guests