Android Port system is terrible!

Discussion and feedback on Construct 2

Post » Sat Aug 16, 2014 10:21 pm

Arima wrote:
Anonnymitet wrote:@PaulloAmaral Ok, I recently discovered that if i changed all my "on every tick event" to "every 0.01 seconds" instead. The performance of the game was greatly and I mean GREATLY improved on all my mobile devices. Try to use as high number as you can. So if you can use on every 0.1 seconds instead then do that.


Are you sure you meant every 0.01 seconds? Every 0.01 seconds should basically run the same as every tick at 60 fps.

I think that would be 0.001 sec
My professional Royalty Free Music at Scirra Assets Store
--------------------------------
Specs: i5 2500, 16gb of ram, gtx 770, win 7, Focusrite Scarlett 8i6, Mackie mr8mk2, Alesis 320, browsing the net on chrome.
B
92
S
30
G
22
Posts: 1,987
Reputation: 20,178

Post » Sun Aug 17, 2014 12:18 am

PaulloAmaral wrote:
Anonnymitet wrote:@PaulloAmaral Ok, I recently discovered that if i changed all my "on every tick event" to "every 0.01 seconds" instead. The performance of the game was greatly and I mean GREATLY improved on all my mobile devices. Try to use as high number as you can. So if you can use on every 0.1 seconds instead then do that.

The small lags here and there just disappeared. So on every tick events are heavier than I thought on the machine.

But crosswalk has never worked for me. Lags as hell and I do not understand how people here has been able to compile a game using it :P



I dont believe changed frame rates could improve performance, if you have a complex game or physics, lag will be there no matter you do.



I tried everything and my game didn't run smooth no matter what. And just before I gave up i tried one last thing and this was to remove all my on every tick events. Nothing else was changed and this made the game run smooth on all my mobile devices. So it has to have something to do with it :P
B
58
S
24
G
14
Posts: 775
Reputation: 13,166

Post » Sun Aug 17, 2014 12:56 am

megatronx wrote:
Arima wrote:Are you sure you meant every 0.01 seconds? Every 0.01 seconds should basically run the same as every tick at 60 fps.

I think that would be 0.001 sec


Nope, 0.01 is a hundredth of a second, which is faster than the framerate of most displays. I just checked, and if no framerate fluctuations occur at 60 fps, adding 1 to two variables, one with every tick and the other with every 0.01 sec, both increase at the same rate (about every 10 seconds the every tick event gets 1 ahead on my computer which currently doesn't have a rock solid 60 fps, so it's close enough to the exact same functionality).

If using every 0.01 seconds really improves performance, there's some other reason and it should be looked into.
Moderator
B
95
S
34
G
33
Posts: 3,007
Reputation: 27,876

Post » Sun Aug 17, 2014 5:33 pm

I exported my game using the XDK and got things running fine the first time round. my game runs perfectly without any big issues

so make sure you design your game for mobile, keeping in mind the limits of mobile cpus and ram
B
43
S
11
G
4
Posts: 428
Reputation: 7,459

Post » Sun Aug 17, 2014 10:17 pm

Arima wrote:
megatronx wrote:
Arima wrote:If using every 0.01 seconds really improves performance, there's some other reason and it should be looked into.


FPS is usually a measure of how often the screen gets updated "i.e. frames". Normally in an application I can run code 1000 times per second (i.e. .001 or each millisecond) and still only update the screen 60 times per second.

Or are you saying that the C2 engine only runs code when it is about to update the screen?

Ok well Ashley answered that down below... "every" only runs per tick ... so the fastest you can get code to run in C2 is at the same rate as the screen updates... (maybe Javascript plugins can run at the native browser rate).
Last edited by ggibson1 on Sun Aug 17, 2014 10:52 pm, edited 1 time in total.
B
21
S
5
Posts: 196
Reputation: 1,984

Post » Sun Aug 17, 2014 10:41 pm

Anonnymitet wrote:@PaulloAmaral Ok, I recently discovered that if i changed all my "on every tick event" to "every 0.01 seconds" instead. The performance of the game was greatly and I mean GREATLY improved on all my mobile devices.

People often say something like this, but I have never seen it proved with measurements, and it technically is nonsense (since "every tick" runs every 0.016 seconds at 60 FPS, and "every" can't run more than once a tick, so will be the same as "every tick"). See Common mis-used events and gotchas.

Crosswalk basically works the same as Chrome which is one of the best mobile browsers available. Some Android devices have audio latency in the OS too. Either way Android L will have the full capabilities of Chrome in its web view so you'll be able to publish with PhoneGap. Also we regularly make tweaks to our engine for mobile browsers - just check the changelogs over the past few releases.
Scirra Founder
B
400
S
237
G
89
Posts: 24,550
Reputation: 195,537

Post » Tue Aug 19, 2014 3:49 am

Anonnymitet wrote:@PaulloAmaral Ok, I recently discovered that if i changed all my "on every tick event" to "every 0.01 seconds" instead. The performance of the game was greatly and I mean GREATLY improved on all my mobile devices. Try to use as high number as you can. So if you can use on every 0.1 seconds instead then do that.

The small lags here and there just disappeared. So on every tick events are heavier than I thought on the machine.

But crosswalk has never worked for me. Lags as hell and I do not understand how people here has been able to compile a game using it :P


It's true about the every tick suggestion,

Instead of Every Tick you get almost the same results with something like
Every 0.05 seconds or something like that :)
B
7
S
2
Posts: 57
Reputation: 591

Post » Tue Aug 19, 2014 5:31 pm

i made one game super unoptimized and it runs no problem on android.
Construct -> intel XDK -> market -> download and install.
the process was super easy.
B
45
S
19
G
8
Posts: 522
Reputation: 8,639

Previous

Return to Construct 2 General

Who is online

Users browsing this forum: No registered users and 5 guests