How do I export for mobile with good results?

Get help using Construct 2

Post » Fri Aug 15, 2014 8:30 am

Hi.

I've been making a new game for mobile devices and it is like an infinite runner but with an actual ending.

My problem is that it has to be precise and right now I can't get in to run smoothly when i export and compile it with cocoonjs for android. There is a little lag here and there that ruins the feeling of the game. It runs super smooth on the pc but not on my Galaxy Note 3 and that phone is a monster so I guess it runs like crap on normal phones :P

The game isn't that heavy and there are about 150 objects total/layout and 40-100 collision checks per tick. Obstacles are not spawned because the whole level is built on a 20 000 x 720 layout where collisions are disabled when objects are "out of view".

So does someone here have any useful tips on how to make a game run smoothly on a mobile device?

And for you who have exported a mobile game with good results. How did you accomplish this? CocoonJs, Crosswalk other?


I've read all tutorials here and can't find a solution. Is it even possible to make a smooth running game on mobile or is it impossible with wrappers like cocoonjs and crosswalk?

Thank you in advance!
Last edited by Anonnymitet on Fri Aug 15, 2014 10:04 am, edited 1 time in total.
B
57
S
24
G
14
Posts: 771
Reputation: 13,133

Post » Fri Aug 15, 2014 9:24 am

Have you tried any other methods? I don't especially have anything to suggest, but I am also interested to hear if anyone has some alternative suggestions. Posting mostly just to follow the thread :)

In this thread there are lots of posts about people's experience with Phonegap on older OSs, though. Might help :)

guide-making-mobile-games-using-construct-2_t62840
B
7
S
1
Posts: 61
Reputation: 588

Post » Fri Aug 15, 2014 9:48 am

When objects are out of layout? I guess you mean out of viewport, because all objects are probably in the layout..

It could be many things,
The size of your images,
A lot of events that are checked/executed every tick,
collisionpolygons with too many points,
etcetera..

Can't really tell without seeing the Capx..
I told my dentist I had trouble with my teeth and asked her to fix it without looking in my mouth..
B
54
S
16
G
8
Posts: 6,160
Reputation: 19,775

Post » Fri Aug 15, 2014 10:03 am

@LittleStain Thank you for your reply. Yes, I meant the viewport. Updated my original post :)

I know but even if I just make a solid ground and a box with platform behavior and make the box simulate running right every tick it will lag on mobile devices. And that is not because the game is too heavy. So I guess I'm just not compiling it the right way.

So I think I haven't found the best way of exporting and compiling my game yet and all the help I can get about this topic is greatly appreciated.
Last edited by Anonnymitet on Fri Aug 15, 2014 10:39 am, edited 1 time in total.
B
57
S
24
G
14
Posts: 771
Reputation: 13,133

Post » Fri Aug 15, 2014 10:38 am

Try exporting the space blaster game... and see for yourself. I used it on crosswalk and it runs perfectly on mobile.
You think you can do these things, but you can't, Nemo!
Just keep reading.
Just keep learning.
B
65
S
16
G
9
Posts: 1,429
Reputation: 12,718

Post » Fri Aug 15, 2014 10:43 am

@DUTOIT Ok, I'll try to export that game and see if there is something I've missed. But usually I get good results when the game fills the viewport and nothing more. But as soon as I make a platformer or something that makes the viewport scroll I see these small lags even if the game consists of only two objects.
B
57
S
24
G
14
Posts: 771
Reputation: 13,133

Post » Fri Aug 15, 2014 11:12 am

Haven't done a platformer in some time, so can't comment.
You think you can do these things, but you can't, Nemo!
Just keep reading.
Just keep learning.
B
65
S
16
G
9
Posts: 1,429
Reputation: 12,718

Post » Fri Aug 15, 2014 9:10 pm

I enabled webGL and also changed all "every tick-events" in my game to "every 0.01second" instead and now the game actually runs smooth on mobile devices. Didn't know that every tick events was so heavy on mobile. But now I know for all my future projects! :D
B
57
S
24
G
14
Posts: 771
Reputation: 13,133


Return to How do I....?

Who is online

Users browsing this forum: No registered users and 8 guests