How do I save images from C2?

Get help using Construct 2

Post » Tue Mar 24, 2015 10:50 am

Message: NickRimer can only post plain text URLS until they have 500 rep. 1 URLS modified. Why?
I have images on local. I can load them to sprite.
I need to to save them all to another place.
Maybe in one folder. Maybe to compress them and save like one file data (zip or smth. else).

What variant could you reccomend? My decision is below but it's not so good as I want.

----- MY WAY (very bad)
Use plugin "jsZip" by @Noncentz705
Use behavior "Extract sprite to base64 string" by @Pode

Code: Select all
1. Sprite -> Load image from URL (FileChooser.FileURLAt(0))
2. Sprite.ExtractImage.currentImage
3. jsZip.AddImage ...

What is bad? Step 2!

Step 2 is long. Image is not big, but conversion takes several seconds. And all program is in idle (fps 0 and so on)! Harder image - harder base64 - more time - more weight.
You can try. In attachment you can find 2 different images jpg 53kb. One is mtg card, another is excel icon.
After zipping mtg card picture in archive will be too big (it is a result of step 2) - 53 Kb image converts to 300 Kb image. Not so good.. But 53 kb of icon converts great to 48 kb..

Take file from here:
Sorry, it's in russian. just click on BLACK button 'Скачать'
Posts: 72
Reputation: 606

Return to How do I....?

Who is online

Users browsing this forum: No registered users and 10 guests