
Use AI to Decompile Any App or Game
People are putting skateboarding inside Call of Duty and Minecraft inside Elden Ring. Most of it comes down to decompiling. Here is what that means, what is legal, and the exact prompts to do it yourself.
Over the past two weeks my feed filled up with games that should not exist. Skateboarding inside Call of Duty. Minecraft running inside Elden Ring. Terraria rebuilt overnight by Claude Opus 5.5. Under almost all of it is one thing: decompiling, which means taking a finished game and turning it back into the code it was built from. This post walks through what that is, where the legal lines sit, and the prompts I used to decompile a game with Opus 5.5.
Watch the video
Modding, merging and decompiling
Modding is changing a game from the inside: new skins, new items, new rules. Gaming communities have done it for decades.
Merging is putting one game inside another, like skateboarding in Call of Duty. Most of the viral mashups work this way.
A full decompile is the hard one. You start with nothing but the finished game, and you end with code that builds into a game that plays the same. The original names and comments are gone for good, so it is never the exact source, but once you have working code you can port the game, fix it, or change anything in it.
Is decompiling legal?
Decompiling is not automatically illegal in the US. In Sega v. Accolade (1992), a court ruled that decompiling Sega Genesis games to make compatible games was fair use. In Sony v. Connectix (2000), reverse-engineering the PlayStation to run its games on a Mac was ruled fair use too.
People get in trouble around it: breaking copy protection, which falls under a separate law (the DMCA), ignoring a license that bans decompiling (a court upheld one in Bowers v. Baystate, 2003), and sharing the code or game files they get back.
Publishers are acting on this right now. Activision got the video on Maurice Heumann's Modern Warfare 2 decompile disabled on X, and Bethesda sent a legal notice to a fan-made Fallout game built with Opus 5.5. That is why I did not decompile a commercial game for this video. None of this is legal advice, and the rules depend on where you live.
How long it takes
Heumann's Modern Warfare 2 project ran about three months and used more than 500 billion tokens, with up to 17 agents working at once. Chris Lewis decompiled the Nintendo 64 game Snowboard Kids in 84 days, against 596 days for its sequel.
A lot of the famous projects also started from years of fan work. Melee, Ocarina of Time and Halo all had human decompilation teams long before AI finished the last stretch.
My test: Late Shift
Decompile the compiled skateboarding game in this folder back into readable C++ source code that builds into a game that plays the same, then make it better. What you have: only the compiled, stripped macOS game in this folder. There is no source code anywhere you're allowed to look. Tools: install REA (`npx rea-agents setup`) with Ghidra as the backend (Java is already installed via Homebrew), and use it to analyze the binary. Hard rules: - Work only from the binary in this folder. Do not search the rest of this computer, other folders, zip files, git history or the internet for this game's source code. - Do not open or try to unlock any zip file or disk image. - Do not look for or download this game anywhere online, including any live web version of it. Method: 1. Map the binary first: entry point, main loop, renderer, input, physics, tricks, scoring, UI. Write MAP.md. 2. Decompile function by function into clean C++ with sensible names you choose. 3. Check your work against the original: run both versions, compare screenshots and behavior (start screen, a trick combo, scoring, the end screen), and fix differences. 4. Run sub-agents in parallel by subsystem once MAP.md exists. 5. Keep PROGRESS.md current: functions done / total, what works, what's different, blockers. Also find: any hidden cheat codes, secret tricks or secret areas, and the exact scoring rules. List them in FINDINGS.md with the evidence (function and address). Then make it better (only after the rebuilt game plays like the original): - Fix any bugs you found in the original while decompiling, and list them in IMPROVEMENTS.md. - Make it run faster: measure frame time and load time before and after. - Add one new trick and one new goal that fit the game. Done when your rebuilt game compiles, runs and plays like the original, FINDINGS.md is written, and the improved version runs with IMPROVEMENTS.md showing the before/after numbers.
Late Shift is a skate game I built with Opus 5.5: one prompt, then a lot of optimization passes. I had Opus turn it into a real compiled app, deleted the source code, and gave Opus 5.5 nothing but the finished game. It used Reverse Engineer Anything, a free GitHub repo that connects Claude Code to the Ghidra decompiler, to rebuild the code, check every piece against the original, and then make the game better.
★ 144,164
Reverse Engineer Anything
Reverse engineer anything with agents, from app behavior down to native binaries.
I will add what it recovered, the side-by-side code and what it improved right here once the run finishes.
Decompile a game you own
Decompile a game I own back into readable source code that builds into a version of the game that plays the same. The game: [game name]. Its main program file is at [full path to the game's .exe or app, e.g. the file inside your Steam folder]. Ground rules (follow these strictly): - I own this game. Work only on the copy at the path above, and keep everything on this computer. - Single-player only. Never touch multiplayer, online services, accounts or anti-cheat. - Do not bypass, remove or work around any copy protection or DRM. If the game file is encrypted or protected, stop and tell me. - Never copy the game's own files (art, sound, levels, the program itself) into the output. The output is source code only, and it loads the art and sound from my installed copy. - Don't download or copy anyone else's decompilation, source port or leaked source for this game. Work only from the file itself. Tools: install Reverse Engineer Anything (`npx rea-agents setup`) and use it with Ghidra (free) to analyze the game file. Install anything else you need (Java for Ghidra, a compiler) and tell me what you installed. How to work: 1. Map the game first: what language and engine it was built with, the main loop, and the big systems (graphics, input, sound, gameplay, menus, saving). Write this to MAP.md in plain English. 2. Before decompiling everything, tell me how big the job looks (number of functions, a rough time estimate) and whether this game is an easy case (C#/.NET, Java, Unity) or a hard one (C/C++ machine code). 3. Decompile it piece by piece into clean code with sensible names you choose. 4. Check every piece against the original. Run the original and your rebuild side by side, compare screenshots and behavior (start screen, a few minutes of play, saving and loading), and fix anything that's different. The original game is the answer key. 5. Once there's a map, split the work across sub-agents by system so it goes faster. 6. Keep PROGRESS.md up to date: how many pieces are done, what works, what's still different, and anything blocking you. Done when your rebuilt version starts, gets through the first level or area, and plays like the original. If you can't get all the way there, stop and report exactly how far you got and what's left.
This is the general version for your own games. Fill in the game's name and the path to its main file, start Claude Code in an empty folder, and paste it in. PC games are the easy case, because the game's code file is already on your computer after you install it from Steam. Console games are much harder, because the files are locked on the disc.
Games written in C#, Java or Unity decompile almost instantly, because the names survive. Games compiled to machine code (C and C++) are the real challenge, and the prompt has Claude tell you which kind you have before it starts.
The slides from the video
Click into the slides and use the arrow keys, or open them full screen.
The ground rules
Only decompile games you own. Keep it single-player and offline. Never share the game's files or the code you get back. And again, this is not legal advice.



Comments
Sign in to join the conversation.