Skip to content

Useful information: HoMM3 Software.

User Avatar
#8
Auto-translated
Archiving game saves and attaching them to forum posts
Of course, you can create archives of games for yourself using any archiving software.
To allow other players and judges to view your game, it is customary to use well-known and readily available archivers.

An archive created with the Zip program weighs several MBs, which is inconvenient for those with a slow internet connection.

Therefore, most players use the 7zip archiver: http://www.7-zip.org/.
Sir_Four
What do we have initially? We have save files packed in gzip format by the heroes themselves. Let's say a game (L+U, two players) ended on turn 227. That means we have all the autosaves from 111 to 226, totaling 41 files with a total volume of 12.4 MB.

The size is not exactly suitable for uploading to the Internet. Most players would say, "Forget about downloading that; I'll pass." But we don't want that reaction, right? So, what can we do about it...

The first thought that comes to mind is, of course, to archive everything into rar or zip! We try. Both archives are 12.2 MB in size. We scratch our heads thoughtfully...

We are advanced PC users and know that there is also the mega-archiver 7zip! We compress the files with this archiver and get a result of 8.02 MB. This is certainly better than previous attempts, but still not suitable for posting online.

And then, unexpectedly, we remember what was said above - our original saves are already packed in gzip format, and each file weighs approximately 313 KB. We make an assumption (and it turns out to be correct, as intuition suggests) that these saves are not optimally compressed. Therefore, our next idea will be to unpack the saves.

They are unpacked by any reasonably advanced archiving software. As a result, after spending some time unpacking and renaming the files (they come out of the archives without extensions, so you have to add ".GM2" to the name of each file), we get a set of files with a total weight of 193 MB.

Anticipating success, fan joy, and other pleasant things, we press the files again into rar or zip. We get 9.86 MB in rar and 12.2 MB in zip. That is, our first attempt with 7zip gave even better results.

Clinging to a straw (because after our old faithful WinRAR failed on the task, all subsequent actions can only be called something else), we pack the files using 7zip. And, lo and behold! The archive weighs only 365 KB (the same number of days in a year, which is already a sign!).

Which is what we wanted. Now the file can be sent by email and uploaded to the forum.

7zip has the ability to set the dictionary size to 8 megabytes, which EXCEEDS the size of one map file by a large margin, while Winrar has 4 megabytes, which is NOT ENOUGH for one map, hence it is not possible to compress strongly with rar.

Therefore, the compression result of 7zip with four saves from one game is almost identical to the compression result of forty saves from the same game.

Of course, a player who encounters the need to unpack and repack saves for the first time will say that this is a difficult process (and so it is, especially with 40 files!). I'll answer: don't forget to use the useful Autosave counter v2 program, which has a function to unpack saves on the fly. After the game, you just need to compress all the files with 7zip and put your pride on display for everyone to see.

HOWEVER: It is impossible to attach such a file to a message on the forum (allowed file types: bmp doc gif jpe jpeg jpg pdf png psd sav txt zip). This is easy to bypass: after receiving the *.7z file, it must be archived in ordinary zip format and attached to the message on the forum.

Summary (briefly and clearly).
Algorithm:

1. We have daily saves, i.e., files like Dunpeal_111.GM2 - Dunpeal_125.GM2. How to do them, see here.
2. Select all files and right-click. In the drop-down menu, select 7-Zip -> Extract here.
3. In the confirmation windows that appear, select "Rename automatically".
4. As a result, we get files of the form [Content], [Content]_1 - [Content]_11.
5. Rename them sequentially by day: [Content] -> 111.gm2, [Content]_1 -> 112.gm2 ... [Content]_11 -> 125.gm2.
6. Select the resulting files and right-click. In the drop-down menu, select 7-Zip -> Add to archive.
7. Choose the archive format 7z and the maximum compression level. Enter a name for the archive: Dunpeal_WC.7z
8. Select Dunpeal_WC.7z and right-click. In the drop-down menu, select 7-Zip -> Add to archive.
9. Choose the zip archive format and enter an archive name. Its size will be equal to the size of one game day, and it can be hidden in the folder with your games' archives, easily sent or uploaded to the forum.
Using the autosave feature allows you to create daily saves that are already unarchived, avoiding steps 2-5.