Welcome, Guest. Please login or register.

Login with username, password and session length



Author Topic: Continually lag then crash  (Read 2441 times)

gdstudios

  • Newbie
  • *
  • Posts: 2
    • View Profile
Continually lag then crash
« on: December 09, 2013, 08:07:56 AM »
Every single game - I can get to about level 20-25, then lag starts.  It will freeze for a second every 45 seconds.  Then a few levels later, every 30.  Around 30-35, it's lagging every 5-10 seconds, then it will freeze, and crash the player. 

This bug has all of the hallmarks of a major memory leak, or missed garbage collection opportunities.  It seems the longer I play, the worse it gets.  I believe it has to do with the map tiles, because it seems to happen more often when moving and not as often when I'm getting bombarded with multiple enemies without moving.

Have you run this thing through a profiler?  I guarantee you'll find some tiles not being removed from memory for some reason.

Thanks - great game!

Kevin

  • Administrator
  • Jr. Member
  • *****
  • Posts: 61
    • View Profile
Re: Continually lag then crash
« Reply #1 on: December 09, 2013, 05:33:19 PM »
Hi, thanks for the bug report!

I do periodically check for memory leaks, I just played through about 27 levels with a profiler active. It did not show any level to level memory leaks. The average and peak memory usage remained relatively constant, allowing for the a small amount of growth from the fact that the levels tend to get bigger.

This doesn't mean that it isn't a memory leak, just that it wasn't replicated in my environment. Some questions:

What browser, Flash version and OS are you using?
Can you tell what Flash's memory footprint is during these lag episodes (some versions of the Flash plugin show up as a separate process)?
Does it seem dependent on the number of levels played, or the depth (i.e., if you start at level 10, does it still show up around level 25)?
« Last Edit: December 09, 2013, 05:35:34 PM by Kevin »

gdstudios

  • Newbie
  • *
  • Posts: 2
    • View Profile
Re: Continually lag then crash
« Reply #2 on: December 10, 2013, 02:49:02 AM »
It does seem to be affected by what level I start at, as more levels == more lag, no matter which one I start at.

I'm using Windows 7, Chrome.  I haven't checked the footprint, but I can guess it's huge since it ends up crashing.

It might help a bit if you would set the right click menu to allow for users to set the quality manually, or allow for a higher starting level depending on your previous performance? 

It doesn't make sense if you are using the same Sprites throughout and they are all being deleted... the levels getting a bit bigger shouldn't make that much of a difference.  Are you using object pooling?  I dunno.  It just sucks to get far and not be able to finish due to performance and not the fact that you are dead.