Sprite Overflow

Hello All!
I’m still relatively new with GDevelop, just getting to the point where I’m figuring out a few things for myself, and can progress a little bit without a tutorial or forum help. I’ve noticed that, whereas in 3D engines things like textures and audio can end up using a lot of space, in GDevelop the main space issue seems to be your project and/or computer becoming overrun with animation sprites. I was wondering if anyone has any hints on this. I found out, a little while back, that you have to be very careful about deleting objects from the project file! Currently, when I add sprites, I save them to the project file, then immediately delete them from my photos, so that I at least don’t have duplicates. I use png format. My plan is, that once I’ve completed and built a game, I’ll just delete the project, and get rid of all the sprites that way. Am I missing anything?

Just some tips:
The only thing you’re missing is to compress the PNGs before add to the project you can do that with RIOT on Windows, ImageOptionm on Mac or directly on the web like compresspng.com
If you want to get the best results in terms of quality and game weight in MB, is a must do to compress all the assets. the same is for music and sounds. Use wav for sounds and mp3 for music.

Thanks! This will come in handy, because, having completed a couple of platformers to get used to the engine, I am now working on the GDevelop version of my sci fi game concept Redirecting..., with 4 scenes: character selection plus 3 playable levels. With 4 characters to choose from, each animated in 8 directions plus idle, enemy ai throughout and a boss in the final level, not to mention background music, sound effects, and at least one cut scene, I’m thinking this is going to be a little bit space-intensive. I make and animate all the content in iClone, which actually partners up nicely with GDevelop. To avoid repeating earlier difficulties I’ve encountered, I won’t even mess with building for online, and will just do a Windows build that people can download. So I just downloaded RIOT. It sounds like I should try compressing/color optimizing one png, then once I am satisfied, use the batch optimizer for all of the images.

i recommend to use GIMP for image optimization.
you can open your images in bulk with gimp (open gimp, then drag all selected images into the layer window), then export them with compression 9 and turn off all checkboxes (so no metadatas are stored), making the image as small as possible, without quality loss.

if you handle alot of images at once, use this plugin to export the layers.

OK, thanks. Just downloaded it.

I ended up using the BIMP plugin with GIMP, and batch processed with the compression set at 9. Is that OK?

i dont know what it does, or if it is useful.
If it works for you then you can surly use it. if you image size is alot smaller then its alright.
if you image file size is still too big, you can go image>mode>indexed and set the number of colors, which further reduces the file size, but also reduces quality.

I used Blender to animate my sprite and on export my 128x128 pixel sprites where about 6kb each. After open it in gimp, indexed to 64 colors, and compressed 9 with no metadata stored the images where around 1kb each.

About compression level

Source here

Compression level
Since compression is not lossy, the only reason to use a compression level less than 9, is if it takes too long to compress a file on a slow computer. Nothing to fear from decompression: it is as quick whatever the compression level.

This is the first time I’ve messed with compressing files, other than zipping something to email it. That is, I really don’t know what I’m doing. I put one of my animations through GIMP/BIMP, a 200 frame idle, each png around 15 kb, and the compression set at 9. It went thru a process, which I thought was compressing it, but it doesn’t seem like the kb’s went down. Even when I figure this out (I also haven’t tried RIOT yet), compressing all of the images I use is going to add a lot of time to the workflow. What a blessing it would be if we could easily compress the images inside GDevelop!

OK, so now I’ve tried both both GIMP and RIOT. Thanks for both suggestions. I personally found reducing file size with GIMP to be complex and time consuming. This may just be operator headspace on my part, as I am very right-brained (creativity over logic). After running into difficulties with GIMP, however, I then opened RIOT, and within a few seconds, intuitively reduced a batch of 60 animation sprites from approximately 15 Kb to 1.5 Kb each, just by changing the color reduction to “optimal 16 colors palette”, and the reduced images look fine to me. Better yet, I don’t see this process adding any significant time to the workflow!

@UlisesFreitas mentioned using compressing.com. Have you tried that? The one I use is tinypng.com. You just drag/upload your images and it just automatically compresses them. Sometimes the compressed version has some weird artifacting, but 99% of the time it works great and compresses them anywhere from 60-90%. It works great for pixel art images, but works for all images. I have found that messing with settings in Photoshop I can’t get any smaller file size that what tinypng.com gives me. You might give it a try.

I made a little tutorial how to use gimp for image optimization