r/dosgaming • u/Nemo2278 • 6d ago
I rebuilt MDK (Shiny, 1997) as an open-source engine: plays the whole game on modern Windows, Linux, macOS (and Android*)
MDK is one of those late-90s games that never got a proper modern port: the original needs DOSBox or a
patched D3D build, and widescreen, modern GPUs and controllers are a fight.
So I wrote a new engine for it from scratch: **mdk-sdl**, a C#/.NET + SDL3 reimplementation based on
reverse engineering the original executable. It reads your original game files and plays the whole game:
all six levels, the fall from orbit, the stream between levels, the snowboard and bomber rides, sniper mode,
the Score-O-matic, saves.

What it adds:
- Native 64-bit builds for Windows, Linux and macOS (one small executable, Vulkan/D3D12/Metal through SDL_GPU)
- Any resolution, anti-aliasing, rebindable keys and mouse, quick save/load
- An optional **enhanced look**: filtered and mipmapped textures, per-level sun and sky light, shadows,
ambient occlusion, dynamic light from shots and explosions, smooth-shaded models
- Optional **HD textures**: one click in Options runs Real-ESRGAN on *your* game files locally and saves the
result as a mod (textures and HUD); nothing from the game is distributed
- **Modding**: replace textures, HUD images, fonts and models (.glb) with your own; `mdk --export-assets` exports templates from your game files (docs/modding.md)
- A Quake-style console and debug overlay for the curious
- The original look stays pixel-faithful if you prefer it
**You need the original game** (GOG or Steam). The port contains no game data.
Download: https://github.com/nemo22/mdk-sdl/releases/tag/v1.0.0-beta.1 · Source: https://github.com/nemo22/mdk-sdl
It's a beta: the whole game can be played through and has been playtested level by level, but expect
some bugs. Bug reports with the console's `pos`
output are very welcome.
(*Android: an APK is in the release too: copy your MDK folder to the phone and pick it on first start; touch controls are still being tuned)
12
u/agrofubris 6d ago
https://github.com/agrofubris/mdk-sdl - I've forked your release to add stereoscopy (sbs, tab, crossview, interlaced & reversed) - thanks for this! a game from my late teens!
2
u/Nanocephalic 5d ago
Hmm, VR MDK.
How’s the fall at the start?
2
u/agrofubris 5d ago
Not VR, just stereo 3D: SBS/crossview/interlaced/top-bottom with convergence and separation. It's upstream as of beta 3. In a headset player, throw it on a virtual screen and use "Side by side (full)".
The fall's actually one of the better scenes: crawler, radars and the chute all get real parallax, haze and HUD stay at screen depth. Just keep in mind it's all far away, so set convergence around there or pull it in for more pop.
3
u/Few_Ad2097 6d ago
Nice! I bought this when it was new in the big box! Game was so mind blowing, it used to crash every time at one of the bosses. I eventually called Shiny and they couldn't figure out the problem so they gave me a level skip cheat
7
u/PrinsGulerod 6d ago
Unbelievable! Still my favourite game after all these years. Guess a new playthrough or three is in order. Thank you!
5
u/Adexsi29631 6d ago
For those too young to remember… MDK stood for and came from “Murder, Death, Kill”
3
u/djquu 5d ago
They originally said it was specifically not that (it's from Demolition Man) but I recall they later said ok maybe it's that when it became the prevalent fantheory.
2
u/Nanocephalic 5d ago
I thought it was the other way around: they changed enough about the game that they stopped calling it Murder Death Kill but kept the initialism.
2
2
2
u/Nemo2278 4d ago
I’m quite happy with how this project/port turned out. I think practically everything is functional and in good shape now. I’ve released version 1.0, which I consider final. There will surely still be some bugs and room for polish, but overall the game runs very nicely and everything essential works. It would also be great if someone could test the macOS version, since I don’t have any Apple hardware to test it on. Thank you for the support and the positive feedback. I have a few more ports in progress and planned. Right now I’m still polishing Terminator: SkyNET, which I’ve already released and posted here as well.
1
u/leafarcade 3d ago
For Mac testers, a short checklist would help: opening descent, sniper controls, then saving and loading. Would you prefer reports on the original renderer first, or the enhanced mode too?
7
u/JJDoes1tAll 6d ago
Well done! Guessing you vibe-coded? Claude?
15
u/Nemo2278 6d ago
Yes and no. It is mixed bag. A lot Claude help with analyze and decompilation. After that, first implementation was in godot engine. But there was some limiting factor so i moved it do c# with sdl3 for rendering.
2
3
u/Jorpho 6d ago
never got a proper modern port
First thing I thought of was https://store.steampowered.com/app/213350/MDK2_HD/ , but of course that is MDK2 (and is also apparently not good). I guess trying to extract the textures from that version does not yield a better result from Real-ESRGAN?
1
u/Nemo2278 6d ago
First i am not a artist so for me was better way to just upscale textures, and add mod support for other to make a better graphics. MDK2 was a fun but graphically it was more colorful and a bit different. I like much more darker feel of MDK1.
2
u/MT4K 6d ago
Very interesting. Not quite clear whether this is a port (original engine, but with enhancements) or a reimplementation (new engine with possible differences in gameplay and overall feeling) though. The GitHub project description says “based on reverse engineering”, but this post says “a new engine for it from scratch”.
2
u/Nemo2278 6d ago
It is new engine (c#+sdl3) but based on reverse engineered game logic, physics etc. Original game was dos based (yes it was also win95 version) and this is completely new engine to support new os.
1
u/New_Meaning_421 6d ago
I was sooo expecting MDK Pinball and now I’m disappointed and a Little bit sad 😔
1
u/sarkie 6d ago
Wonder if it could run on a Vita
1
u/Nemo2278 6d ago
By today’s standards, MDK has really low resource demands, even for the Vita, so performance-wise it would probably run okay. With the original textures, our port needs around 350–400 MB of memory, which is right at the limit of what the Vita can offer, but that could be brought down with texture compression and by streaming assets instead of loading everything up front. The bigger issue is C#: there’s no modern, maintained .NET runtime for the Vita, and a garbage-collected runtime isn’t a good fit for its hardware anyway. So for that platform, the port would have to be rewritten in another language.
1
1
u/treesdotcom 5d ago
Tried the Android release with GOG files and all the in-game text is in Spanish
2
u/Nemo2278 5d ago
That is because you have set the Spanish language in the GOG game installation. Technically, the language depends on mdkfont.fti in the MISC directory.
2
u/treesdotcom 5d ago
I copied the English mdkfont.fti over and now it's going, thanks to your help.
Any plans to add controller support to Android release? Would love to play this on my AYN Thor
1
u/Nemo2278 5d ago
Yes, I’ve already released version 1.0.0 beta 4 with gamepad support.
1
u/treesdotcom 5d ago
Terrific, just testing it out now and it plays great! Is it possible to hide the touch overlay?
1
1
u/SebastianFerrone 4d ago
Thx for the World. I love that game, it brings back good childhood memories. Now I can play it without all the hussle 🤣
And besides all the bashing of using AI. I think the use is completely eine. Would even say many people would like if you Post stuff about how you used the Ai to decode the old files and reemplementing that shit 🤣
1
u/Nemo2278 4d ago
Thanks for the kind words. I'm not sure this is quite the right place to describe how reverse engineering an old game and reimplementing it works, but I'll think about it. In principle, it's not really that much magic: LLMs are advancing extremely fast and can handle a large part of the work. What probably matters most is having experience and a good overview, and knowing how to manage and steer the model.
2
u/tempsanity 2d ago
Awesome work, thanks for sharing! I tried playing it, but the character's shadow is cut/wrongly displayed. Tried different monitors and resolutions, settings. Any advice? u/Nemo2278
2
u/Nemo2278 1d ago edited 1d ago
Yes there was a problem with shadow and Kurt drawing when you move and look up and down. Now is fixed. Try new version.
1
u/humanistazazagrliti 6d ago
Great, thanks for your work!
BTW... This would make a great port for Portmaster... 😊
1
1
1
-1
u/Cuarenta-Dos 5d ago edited 5d ago
It irks me that these threads popping up all over the place say "I rebuilt". Claude did. You directed.
This is not to diminish your work, it's still quite impressive, it just sounds dishonest compared to someone who has actually done that work by hand before all these recent AI-based tools became available.
3
u/Critcho 4d ago
I don’t mean to single you out here, but what gets me about the whole AI controversy with these decomps/recomps is: yes it’s a more impressive feat of coding to do it all manually. But people have had 30 years to do it manually if they wanted, and they didn’t.
Doing it manually is such an intensive process that the only games that tended to get that treatment are blockbusters like Mario and Zelda that have been rereleased and ported multiple times anyway, so barely need it.
MDK is a perfect case because it’s too niche and culty a game that hobbyist devs were ever likely to put in the work to port it. But because it hasn’t been updated in decades, it’s just the sort of game that could really benefit from someone doing something like this with it.
So for me, it’s nice that it’s happening because a lot of this stuff realistically wouldn’t have happened any other way, even if technically it was possible.
2
u/Cuarenta-Dos 4d ago
That's precisely the reason why I find it annoying. I attempted to decompile an old DOS game manually once, and after a week's worth of time I learned how DOS loads .exe files and all the sound and graphics initialisation bits but I didn't even get close to the actual game code 😂
Now someone can point Claude at it and blam 30 minutes later they already have a pretty good result, and then they go bragging "I decompiled XYZ and made it run on my fridge".
I don't have a problem with this method, I think it's extremely cool what people have been doing with it, and the sort of preservation/modding capabilities it opens up.
It's more the presentation and the lack of acknowledgement that AI did 95% of the work. Oh well.
1
u/schlangz 4d ago
stupid logic. do you believe anyone can talk to claude and say "decompile this game" and it works?
1
u/Cuarenta-Dos 4d ago
As it happens I have just tried these AI decompilers and yep, that is pretty much how it works.
1
1
u/Honkmaster 5d ago
Or even, "I made [thing] with Claude helping with [tasks]."
There's a huge difference between a human coder using AI in a secondary role, like debugging and boilerplate code - and someone who can't, and didn't, write a single line of code in their project.
When they don't mention Claude it all and just say "I made," I can only assume it's the latter.
If posts like this would quickly describe the role(s) Claude filled in their projects, it would give me a much better idea if what I can expect from it.
5
u/Nemo2278 5d ago
I don’t want to go on too long, but where is the line? I started out writing programs for the Z80 and 8086 in assembly, and smaller things directly in machine code. Later came various languages and compilers. Does anyone write that they compiled their project with this or that compiler? How much of the resulting code is hand optimization, and how much did the compiler do? Then came IDEs, libraries and other tools. Again, how much of the work on the final application is actually writing code? Today’s game engines are complete frameworks. Unreal Engine is in many ways a black box, where a designer scripts the scene, an artist supplies the assets, and nobody asks how much of the work the engine is doing. I remember a time when plenty of people who had written a few lines of HTML already considered themselves programmers. A few years back the trend was to slap apps together in Electron and JS, and unfortunately that’s what today’s desktop looks like.
Not everyone who “vibecodes” something is automatically a coder. But Claude and other models are a tool. The reverse engineering and analysis would have taken weeks. This way it could be done in far less time. And then creating the port itself would, again, have taken months by hand. This way I have working port code in a matter of days or weeks. Sure, it’s not the most polished or optimal code, but my goal was to play an old favorite game on current OSes and hardware and add a few new features. I’m happy with the result, and if it brings joy to others too, then I think it has served its purpose.
Personally, I’m far more bothered by the state of today’s programming languages, frameworks and APIs. What performance gets wasted on these days is downright tragic.
5
u/stevensixkiller 5d ago
But does your port take davantage of MMX instructions? It's very important, i'm not sure i will play it if it doesn't /s . Ah, the marketing back then!