Join the discussion

Write your take first — we'll ask for email only when you're ready to publish.

  • Hacker News
  • I think Marx is rolling in his grave over the tirelessly expended human to recreate what almost definitely already exists on a floppy sitting in some “IP - Do Not Touch” lock box. But maybe endless puzzles for ever cleverer people is the point of it all.
  • That's better than the games not being made in the first place because the Ministry of Culture deems it unimportant and puerile, which is what happens in Communism. You also can't have indies, because you can't publish anything without the state's approval, not to mention you also can't sell things for monetary gain.

    I think 80-ish days to recompile and old binary is a much better alternative to the total death of human arts and innovation, and the unending list of crimes against humanity that Marx's theory has led to every time it has been applied.

    But to keep it a bit more videogame related, Marx always reminds me of this speech by senator Armstrong of Metal Gear Rising: https://www.youtube.com/watch?v=IMpuUUV2HeE . "We will use an absolute totalitarian state to abolish the state" - a lofty goal turned into complete lunacy.

  • I dunno. I was a gamedev. I'm pretty sure everything got thrown out. I don't remember ever taking any source home. It was all managed through Visual Source Safe (!) on a local server.

    The 80s games were mostly coded in bedrooms, but after that it all moved to teams in offices and a lot of studios went boom-to-bust pretty quickly.

  • Yeah I am decompiling a PS2 game. It's not easy but I think I finally have the right setup.
  • Also been working on PS2 stuff. It's been very fun!
    by aap_
  • Sounds cool, please document your steps and pitfalls. I would live to try this one day.
  • Awesome. Hopefully AI will allow more games to be decompiled in the future. Anyone working on a decomp of Perfect Dark?
  • https://github.com/n64decomp/perfect_dark claims to be “a complete decompilation of Perfect Dark for the Nintendo 64”. And: “When a matching decompilation is compiled with the same compiler that the original developers used, the output will be exactly the same as the retail game, byte for byte.”

    Relatedly, https://github.com/perfect-dark-pc-port/perfect_dark forked from the above describes itself as “a work-in-progress port of the Perfect Dark decompilation to modern platforms”. Further: “The game is in a mostly functional state, with both singleplayer and split-screen multiplayer modes fully working. There are minor graphics- and gameplay-related issues, and possibly occasional crashes.”

  • LLMs are truly amazing and I hope those decomp will keep coming! I am currently watching the Test Drive Unlimited decompilation project, which seems to use a mix of LLM decomp and actual engine improvement (porting the game to Vulkan and a new physics engine instead of Havok): https://github.com/opentestdriveunlimited/OpenTestDriveUnlim...
  • For people who've done matching decomps: what burned the most calendar time for you, toolchain freeze or the last 5% of non-matching functions?
  • I had no issue with the toolchain, as I happened to work on a game (ZZT) whose toolchain of choice was documented by the author himself (well, he was off by one Turbo Pascal release). Lucky!

    What took me the most time was actually the beginning: building a mental model of what assembly patterns map into which Pascal patterns, and finding good areas to start writing code from. In hindsight, I should have probably started by generating inline assembly equivalents of each procedure/function. The ending was relatively smooth sailing in comparison, but it is of course much easier if the compiler you're targeting doesn't do much in the way of optimization passes, so it's not representative of decompilation work for more modern targets.

  • I just did one last weekend, but it is a game that was clearly written in assembler in the first place (Elite 8088 CGA).

    Trying to reconstruct the original build environment that Andy Onions (where are you?) used took some time. It was assembled with 16-bit MASM, but you can't easily run 16-bit exes under 64-bit Windows, so a bit of a kludge to set up DOSbox where the LLMs can push/pull in-and-out of it while being able to drive it enough to execute MASM and read the stderr and output files etc to get a feedback loop going.

    Making up plausible function names and branch labels was pretty quick for LLMs.

  • > One small but useful improvement was to give every task an explicit deadline and expose that deadline to the agent.

    I’m really curious about trying this myself. Recently I’ve been handing off tasks for agents to complete on their own more and more. While their work is acceptable I’ve found them to not only take a long time to complete it, but they often add too much complexity and tests.

  • Its really great how we can breathe new life into older games like this. I'm currently working solo on a Tales of Symphonia gamecube decomp. My aim is to let AI do everything of substance. currently about 3400 functions are exact out of about 4800. So still a way to go. But I haven't written a single line yet.
  • How did you get started? I have a project in mind and would love to try, but getting a foothold on it feels really hard when you are starting with an ISO image and an empty folder.
  • What's the legal status of these?

    Historically there was a notion of "clean room" reimplementation.

    These days it seems people translate the actual game code into a different representation of that same code and that makes it open source? Github is full of these.

  • Historically these projects have gone to match byte for byte recreations which ensures that they are derivative works making them infringing copyright.
  • Clean room might get you past copyrighted code, but surely it won't get you past trademarks or copyrighted artistic work?
  • There was a decompilation project of GTA 3 and Vice City. It got DMCAed by Rockstar Games, despite requiring the user to provide their own game assets.
  • It seems like it could go either way to me in the US (not a lawyer, but someone who has a fair amount of experience in reverse engineering / fair use issues).

    On the one hand, it is fairly clear that producing source code with the explicit goal of reproducing a 1:1 binary is in no way transformative, so that's out. This would be a really hard argument to even attempt.

    On the other hand, these projects are mostly free, intended for owners of the game to play the original game on a different platform or in a modified format, and not likely to have a negative effect on the original work's desirability or value. And, the reproductions aren't complete and alone usually produce limited to no value to a consumer (usually, they won't start without the original game files). These are the other important factors considered in fair use determinations and generally go the way of these being OK.

    So, it's hard to say. With reverse engineering and copyright in the US in general, context is crucially important; something that would be completely illegal for one purpose (ie - decompiling and recompiling a competitor's software to distribute it without a license or use it internally without purchasing it would be obviously illegal) could be OK for another one.

  • > Historically there was a notion of "clean room" reimplementation

    These projects start off with the original assembly code and use it actively throughout all stages. This is about as far away from clean room as you get.

  • Mildly related, but I have been waiting for goldeneye to be decompiled for a while but before that process has finished there is has been a spiritual successor(?) made that has scratched the single-player itch for me: https://store.steampowered.com/app/1574480/Agent_64_Spies_Ne...

    Worth a look if you want a bit of nostalgia.

  • I saw some news last week saying the project had reached 100%. Looking at the git repo (https://gitlab.com/kholdfuzion/goldeneye_src) that claim is a bit harder to verify, but maybe look again?
  • If you are interested in the "sequel", Perfect Dark, then there is this PC port based on the decompilation project that plays great:

    https://github.com/perfect-dark-pc-port/perfect_dark

    Ported it to OpenBSD for fun an evening about a year ago.

  • I’m surprised the game companies themselves aren’t interested in these projects.

    Seems like easy money to just decompile a retro game, add some quality of life improvements and stick it on steam.

    Are their hands tied by legal or what other factors are preventing this?

  • I don't know how they made it, but there was a GoldenEye made for Xbox 360 that seems to only update the UI. The controls are maybe a little different, but you can swap between original and updated renderer in game. Anyway, they couldn't ship in the end due to legal stuff.
  • >Are their hands tied by legal or what other factors are preventing this?

    Nightdive studios has a few blog posts regarding this.

    The problem apparently is that a lot of retro game IP changed hands when records were physical.

    So Nightdive goes to Company A and says "Hey do you have the rights to <Game> or did you sell them"?

    Company A says "You can pay us 50,000 dollars to check our records we are not sure."

    Nightdive says "Ok, seeing as you dont know if you own the game, could you give us permission just in case you do"

    Company A: "No, we would need to review the records. However if you released the game to market, we would check just to see if we can sue"

    Nightdive has an identical conversation with Company B, who may have bought the rights from Company A but only have archival records.

    Nightdive walks away from the project.

  • Yes many games are caught up in IP hell.

    Including the one my username is inspired by. It's why you see a lot of fan remakes. Another sad side effect of corporate owned IP is also a lot of times the individuals who did the bulk of the work on something can't be the ones to do a remake. They don't own their own work. A company owns it. That's what most of us sign up for to get a paycheck. But when it's something like film or games, the effect on artists or designers can be pretty depressing.

    So yes, games are not unique in this way. I am hopeful in the optimistic future case where LLMs lead to lower barriers to entry, UBI, and so forth that copyright essentially disappears, or at the very least is severely reformed.

    Many things should simply enter the public domain at a far more accelerated rate.

  • > Are their hands tied by legal

    Yes.

    Even if you're the owner of the game, the contracts for the voice actors, motion capture, models, etc. frequently define very narrow terms of usage. Defining the exact release platforms is common. Not to mention profit sharing if the actors or studios you're hiring are popular.

    It's even worse for retro games. Many times the original rights holder went out of business, sold their rights, died, or something else that muddies the ownership chain.

  • It's pretty amazing what you can do when you embrace LLMs, figure out how to build one high-quality rigorous project with them, and then start working on more projects.

    You become a machine with your workflow, once again limited only by your time/energy, tokens, and your discretion on how to spend it.