What is the best practice to track crashes on mobile

For developers using the Construct 2 Javascript SDK

Post » Fri Oct 24, 2014 9:47 am

Hi

I am puzzled, my game on PC never crashes, but it does occasionally when porting it to mobile (crosswalk).
from your experience, what is the best approach to track down what is causing the crash?
is there a way to at least tell which event it was on before the crash?

thanks
B
7
S
1
Posts: 26
Reputation: 530

Post » Fri Oct 24, 2014 12:08 pm

Crashes (as in the app exits) are usually caused by buggy graphics drivers, or running out of memory. In rare cases it may be a browser bug, but the first two causes are far more likely. There's not much you can do about buggy drivers; most mobile platforms don't allow updates outside of updating the entire OS, which is subject to the carrier/manufacturer approving the update.

If there's a bug in the C2 engine then if the JS code goes wrong it probably won't crash the app. It will probably freeze instead, since the browser engine catches the JS error, halts the script, and then continues running the page. That's useful in web pages but since the C2 engine is all JS then the game logic halts freezing the game then the last frame remains on-screen. If that happens then ideally you'd be able to reproduce it and report it as a bug to us so we can fix it.
Scirra Founder
B
399
S
236
G
89
Posts: 24,525
Reputation: 195,382

Post » Sun Oct 26, 2014 10:23 am

Ashley wrote:Crashes (as in the app exits) are usually caused by buggy graphics drivers, or running out of memory. In rare cases it may be a browser bug, but the first two causes are far more likely. There's not much you can do about buggy drivers; most mobile platforms don't allow updates outside of updating the entire OS, which is subject to the carrier/manufacturer approving the update.

If there's a bug in the C2 engine then if the JS code goes wrong it probably won't crash the app. It will probably freeze instead, since the browser engine catches the JS error, halts the script, and then continues running the page. That's useful in web pages but since the C2 engine is all JS then the game logic halts freezing the game then the last frame remains on-screen. If that happens then ideally you'd be able to reproduce it and report it as a bug to us so we can fix it.


Thank you, this makes a lot of sense.
I am aggressively using the Canvas plugin and there is no comparison between PC graphics driver vs mobile.
although I am streamlining the Canvas update to be every 1/60 seconds
May be I need to do more work to prevent overlapping of the same events that work on the canvas. by setting and clearing a flag at the beginning and end of the event.
B
7
S
1
Posts: 26
Reputation: 530


Return to Javascript SDK

Who is online

Users browsing this forum: No registered users and 0 guests