• Hey Guest! Ever feel like entering a Game Jam, but the time limit is always too much pressure? We get it... You lead a hectic life and dedicating 3 whole days to make a game just doesn't work for you! So, why not enter the GMC SLOW JAM? Take your time! Kick back and make your game over 4 months! Interested? Then just click here!
  • Hello [name]! Thanks for joining the GMC. Before making any posts in the Tech Support forum, can we suggest you read the forum rules? These are simple guidelines that we ask you to follow so that you can get the best help possible for your issue.

Legacy GM Help with External Files

Valerie

Member
Hi friends! 👋

I make a lot of pseudo-3d games with rendered cutscenes that use animated sprites. Despite heavily compressing them, they tend to eat up Gms1.4s rather limited memory quite fast.

Id like to store all of the animated sprites for a particular level in an external folder, and then, at the beginning of that level, load them in and load out the other ones.

is this possible? Are there any workarounds?

💜🙏
 

YellowAfterlife

ᴏɴʟɪɴᴇ ᴍᴜʟᴛɪᴘʟᴀʏᴇʀ
Forum Staff
Moderator
You can use sprite_add and sprite_delete to load/unload sprites when necessary.

Compressing them will not help with memory use, as images have to be uncompressed for GPU to be able to draw them (saving for specific formats like DXT that cannot be easily used in GameMaker).
 

Valerie

Member
@YellowAfterlife thanks for your help!!! Would you suggest creating a manual loading screen while that’s happening, or is it pretty instantaneous?

just wanna make sure it won’t cause the game to freeze at the beginning of each level while that’s happening
 

YellowAfterlife

ᴏɴʟɪɴᴇ ᴍᴜʟᴛɪᴘʟᴀʏᴇʀ
Forum Staff
Moderator
@YellowAfterlife thanks for your help!!! Would you suggest creating a manual loading screen while that’s happening, or is it pretty instantaneous?

just wanna make sure it won’t cause the game to freeze at the beginning of each level while that’s happening
Loading time depends on the size of the image(s).
You can show a loading screen as needed by measuring time it takes for sprite_add (by comparing current_time from before and after the call) and letting the game draw a loading screen frame once it exceeds a threshold (e.g. 50ms)
 
Top