HTML5 game size limit

  • Hi all,

    I'm working on a game of mine : scirra.com/forum/viewtopic.php Spooky Heroes.

    I'm having some problems after adding lots of objects to the point where Chrome and Node Webkit do not work anymore. Firefox seems to randomly either crash or work.

    The problem appeared after I added 2 new characters to the game and I had similar issues before when the size of the game became to big. I had to optimize all images but now, I have not much left to optimize without reviewing the whole structure of the game... I would like to avoid that.

    I would like to know if there were any limits in size to HTML5 game, aiming to be used as desktop game, not online. I'm aware Node Webkit is just a simplified Chrome browser so I guess the same restrictions are in order for desktop games coming from Construct 2.

    Currently, my game indicates 33.6 Mb of download size and 61.4 Mb of memory use.

    I have created around 20 layouts used to preload game sprites.

    Is there any way to know why the game won't launch in preview with Chrome or Node Webkit ? (any log files ?)

    Are there any download limit or memory use limit for HTML5 games ?

    Any answers would be really appreciated !

    Thanks

  • My largest game is 120mb. I believe the game Our Darker Purpose is closer to 300mb.

    My games memory use largest point is 400mb.

    I suspect the problem is elsewhere. Very likely you are using some seriously inefficient assets. That how is just an assertation based on the little information. I would suggest checking the tutorials on "Don't waste your memory" and just a tutorial search for "performance"

  • Thanks for the reply.

    I've already read all the tutorials about performances and memory and have been optimizing the game as explained.

    I have many different characters and boss with their own animations. When I delete a few random of them, then the program works fine. As soon as I put more than a size limit (it seems), it just crashes.

    I've uploaded the capx so if any of you could look at it and tell me what could cause the problem, that would be a great help.

    Actually, I'm also thinking the problem might come from my computer so if you could just try to preview the capx with node webkit of chrome and tell me if it's working for you, that would pinpoint the problem.

    http:///www.gaweb-studio.com/SH.capx

    Thanks !

  • My post was destroyed. I'll ask a quck question though.

    are you developing your game as a CAPROJ or a CAPX?

  • I save as capx.

    Is there a difference ?

  • A little bump, I'm still having troubles and still don't know why Node Webkit and Chrome won't work.

    The strange thing is that the Construct 2 loader starts normally but instead of seeing the normal blue bar filling up, the bar is red, and when reaching 100%, nothing happens. It does this on Chrome and Node Webkit, whereas Firefox works fine with the blue bar loading.

    Is there any way to display the list of assets loaded to check which one would cause the problem ?

    Or is there any documentation about how Construct 2 load things (only read how the load works : loading layouts one by one but besides that, not much info)

  • Well yes there is a massive difference.

    A CAPX is a zip file. When C2 saves a game C2 needs to compress the assets to the zip file. If C2 needs to get assets for preview I would also suppose C2 will need to extract and push. While although the prgram shuoldn't get stuck it is. CAPX is good for small games, sharing small projects, sharing bits of code. Once a game hits the big time with alots of assets.

    A CAPROJ is all the assets inside foders and sub folders. There is no compression of all assets to a single file. This is good for larger projects.

    I unpacked and saved as a CAPROJ into a folder and boom. Changes

    10 seconds to load the project

    10 seconds to run the game sucessfully.

  • I didn't know that.

    I'll give some try with capproj then.

    Thanks for the heads up !

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • Daedolon Did it work? The red loading bar or percentage text is showing up on mine now too, since I updated r184 + put some extra files in there, and it behaves the exact same way. Whole game isn't more than 150mb.

  • Your project uses nearly 7000 separate images. That is insane. I can't comprehend why you could need such an extraordinary number of images. Do you have an object with 5000 animation frames or something?

    The problem is not the overall memory use, but once you start getting close to 10,000 images, you start to get close to a hard-coded Windows limit of how many separate images you can be working with at once.

  • BTW it looks like you're using animation frames as tilemap tiles - that's going to use up a lot of images, and the Tilemap object does that a lot better, so that's one thing you can do.

  • lol Ashley

  • Yes I just started getting the Red loading bar of death on my project too since updating to r184. I only have 428 images after export. they are all of various sizes though, and unoptimized to use power of 2. Anyone know how to image loading error or what causes it?

  • suntank - did you check the browser console? Do you have 7000+ images in your project as well? Spritesheeting on export will significantly reduce the image count, preview mode can be using vastly more images.

  • You don't need that many images to create game. If you are good programmer you would sit down and plan the game ahead. One can use same images many times by changing orientation and sizes or sprites manipulation. I am not clever as Ashley but, I know thing or two. Common sense that many images will slow down any pc or android has no chance

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)