Hello everyone! Dungeon Keeper 2 is one of my favorite childhood games. To play it now, you need to run DKII-DX.EXE, which, unlike the original DKII.EXE, does only one thing. It replaces the import of DDRAW.dll with PATCH.dll. PATCH.dll applies some patches that allow you to run the game on windows 10. Its source code is closed and somehow changing it to add your own developments is problematic.
I have been reverse engineering DK2 machine code for about a year now and trying to write machine code patches for this game. As a result of my work, i have created a game launcher that patches the machine code of the game right before it starts, and it does not using any patches from PATCH.dll.
At the moment, patches does this:
- Adds support for Windows 10 when checking operating system version
- Removes the use of dinput in the game code and replaces it with user32 window messages.
- Forces the game to run in windowed mode, you can scale it as you want and it's mostly for reversal purposes
- limits the game's frame rate to 60, so in-game animations don't run as fast
- Adds the ability to collect information about the crash of the game so that it can be fixed later
The binaries: https://github.com/DiaLight/Ember/releases
There is source code, so you can check and compile it by yourself: https://github.com/DiaLight/Ember
Don't actually know where to improve the game next. This will likely be fixes to the game menu and some day i'll figure out how to run game with higher resolution textures.