Since the start of the project I’ve been adding integrations to the project.
In case anybody is interested, I’ve been doing the following:
Setting up a gitter chat community.
This was really easy to set up, just a bunch of clicks.
I thought this would be a great way to enable others to reach me to collaborate with the project.
Setting up a project on github.
This is a simple agile-board, just to get a sense of what remains to be done. It could be great for collaborators to be able to pick a task and make sure that is going to be useful work.
Setting up a build server on AppVeyor
This has been a great way for me to make sure the project compiles successfully on other machines (other than testing on 2 PCs of mine). This should later allow to download a compiled version of the tool from the artifacts section.
Also, it automatically runs unit tests, so it should give a good sense of the builds health as soon as there’s more unit tests.
I’ve started to look into code coverage analysis.
I’m currently using OpenCover with ReportGenerator, but it’s still work in progress and will probably need a bit of love before merging to master.
I’ve got most of the info I needed from here.
As I’m writing this post, I’m waiting for the extractor tool I have to give me some result after adding a bit of code with timing info (just total duration), since the export is taking an enormous amount of time.
So what I have been doing between the previous post and this one is trying to understand 2 file formats that the game uses that I don’t export from yet.
One of them is called DBI, which seems to custom made, it contains an Autodesk license (on text, like you would write it on code file), and even error messages for things I don’t think I’ll ever seen inside the game.
As my experience reading through undocumented binary formats that I haven’t written is limited, I had to call it a day and leave the DBI files format unsolved.
The other one is the FF file, that starts with the magic word “MFF”. I haven’t found any reference to it online, so I started looking at it on my own. These videos from Mr House helped a lot on this.
I think I understand the file format, so here’s the file structure for the FF file (there’s only one file like that in the game) is more or less as follows:
4 bytes, magic word MFF, followed by \0.
Index of files in the archive header
4 bytes with the amount of files in the archive.
An entry for each file
256 ASCII chars, file path
4 bytes, offset to the file contents on the file.
4 bytes of 0’s.
Start of file data.
Each file here is an SMK2 file, so my converter for SMK files can read this.
There’s no hint (that I’ve been able to find) of each file size.
I’m currently guessing the file size by reading the SMK2 file header and trying to add up, but I’m probably not doing that perfectly, since the SMK2 file format specs I’m using are not official.
After reading through the FF file more or less successfully, I will only need to read through the DBI one and I should have access to everything!
as mentioned on my previous post, I’m working on a remake for Liberation Day in Unity.
To be able to remake this game, I aim to extract assets from the original game during installation time and use those assets from the newly written code.
Legally speaking, I won’t be able to distribute the game assets, so each player will need to get a copy of the original game to play and run an extractor tool to get the assets from the original game into the remake.
Understanding the game data formats, what are they used for and find how to implement converters for them is going to be the greatest challenge of the remake, I think.
So far, I’ve managed to read through the 2 formats I already mentioned and managed to read and export them to more “modern” formats:
SMK files. They all start with the Magic number SMK2, which helped me find that they are Smacker Video files. The game has some videos made with this, but also has interface assets stored with it. I’ve managed to open these with ffmpeg and export each keyframe to png. For that I’ve used FFmpeg.AutoGen, since I needed a C# wrapper around the C++ libraries.
MDB files. These are Microsoft Jet databases, opening them with Hex worshop revealed another magic header “Standard Jet DB”. Through mdbtools, I’ve been able to see the game always uses version 3 of MS JET DB, which I’ve been able to open through an OleDbConnection. Some of the databases on the game are password protected, but thanks to mdbtools being open source, I’ve been able to quickly read the passwords from the password protected ones and all of them are now TSV files.
There are still big challenges ahead, specially since I’ve only been able to get interface assets and databases. There’s a file called ANMSUNIT.FF, that uses a completely unknown format (probably custom made) that seems to hold all animations for units, probably with the units assets. There’s also DBI files, which seem to hold some kind of images, since they are stored in an IMGS folder.
It’s been literally years since I don’t write on this blog. I’ve been very busy since then on work stuff, which will now allow me to write more interesting stuff than what I could write back at 2012 or 2013 😀
The reason I’m resurrecting this blog is because I have decided to work on remaking Liberation Day (gameplay here https://www.youtube.com/watch?v=6YtyTmItD6A), a turn base strategy game from 1998. This game is also known as Fallen Haven 2, since it’s the second part of a more famous title, also turn based strategy game.
I plan to create a github repository with the game and tools related to it, as soon as there’s something worth to share.
This project has many challenges, which will require me to learn a lot of new things, that will probably be well suited for blog posts.
I hope this blog will also be a good way to have somebody interested on working on this with me, so this project is not only something I work on weekends when I have some time to spare, but something bigger.