How do I optimize memory usage .

0 favourites
  • 3 posts
From the Asset Store
Test and challenge your memory in this amazing Christmas themed memory game!
  • Hi guys, I am making a PC game. from what i understand, since almost all laptops have MINIMUM 4 GB of ram, I was thinking that a Pc game can have arround 2GB of ram usage ...is that ok in ur opinion ???

    I have really maaany sprites with many frames.... the max size is arround 500*500 pixels...but mainly arround 270*270.... any tip to optimize ?

    thanks

  • You might have confused RAM with VRAM. The amount of VRAM available to a system is generally significantly less than the total RAM available.

    Even so, 2GB of free RAM out of 4GB is pretty optimistic, maybe if the user has nothing else open.

    This article has many tips on reducing memory usage in images - https://www.scirra.com/blog/112/remembe ... our-memory

    Some quick tips:

    Use power of 2 image sizes - your 270*270 image takes up the same amount of memory as a 512*512 image (actually Construct helps you out a little here, but it is still a good idea to do it manually). If you reduced the size to 256*256, it would be 4x less.

    Try to group up your images into layouts - don't use images you don't need for that particular layout. Anything that isn't used in each layout is not loaded into memory.

    Avoid transparencies as much as possible. Even if you don't see anything, it still takes up memory.

    Cut down on animation frames. A professional artist can convey a LOT of information in just a few frames with technique. Someone posted this video a little while ago and its a great way to see how pros do it.

    Subscribe to Construct videos now

    Similarly, check if some parts of your animations can be broken off into their own objects. For example, if you have 10 animation sets for when a character swings 10 different swords, instead make one "swing" animation for the character, and have the swords as separate sprites.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • thanks a lot 4 ur Help...very informative !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!

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