Getting an AI to write code that looks right is easy. Getting it to write code that is provably the same as a 2009 shooter's is a different job, and it cost somewhere between 600 and 700 billion tokens. Developer Maurice Heumann has described how he used AI agents to reconstruct the source code of Call of Duty: Modern Warfare 2 (the 2009 release), and the interesting part is not the writing. It is the checking.
What was done
The project took roughly three months. Heumann used two commercial models to analyse the original code: Claude from Anthropic and Codex from OpenAI.
The workforce grew as the work did. At the start there were four AI agents. By the end of September there were 17. His estimate for the total bill is 600 to 700 billion tokens, a figure that makes a monthly API invoice look like pocket change.
The real problem was trust
Writing code turned out to be the cheap part. Proving that the code matched the original was the hard part.
Early on, the models produced implementations that were pleasant to read. They were also wrong in the ways that matter when you are trying to recreate a specific binary. The agents made mistakes in data types, function signatures and program structure. Sometimes they simply changed the logic on their own initiative, which is a charming habit in a colleague and a disqualifying one in a reconstruction tool.
The fix: a referee that cannot be charmed
Heumann's answer was to stop relying on how plausible the output looked. The team automated a comparison of each recovered function against the original executable, down to the byte.
They also switched to the same compiler that had been used when the game was originally built. That matters because identical source compiled with a different toolchain will not produce identical bytes, so a mismatch could mean a bug or merely a different compiler.
With those two changes, every function got a binary verdict: it matched, or it did not. No partial credit, no "looks reasonable to me."
| Setup | Detail |
|---|---|
| Project length | About three months |
| Models used | Claude (Anthropic), Codex (OpenAI) |
| Agents | 4 at the start, 17 by the end of September |
| Token spend | 600 to 700 billion (developer's estimate) |
| Verification | Automated byte-level comparison against the original executable, using the original compiler |
The results
Heumann reports that 99% of the game's functions were recovered. Of those, 83% match the original byte for byte.
The remainder is less tidy. By his estimate, a significant share of the functions that do not match exactly still behave correctly in meaning, in other words they are semantically right even if the compiled output differs. The game launches and runs.
Two caveats are worth keeping in view. The percentages come from the developer himself, and the report does not say how the semantic-correctness estimate for the non-matching functions was reached. A byte-identical function is a hard fact. "Probably works" is an opinion, even a well-informed one.
The part with lawyers in it
Heumann also made a plain statement about the legal position: decompiled code is, obviously, protected by copyright. Activision, he says, has applied pressure over the project on copyright grounds.
The effects were concrete. Two earlier posts on his blog were taken down, and a video in a post on X was disabled after a complaint from the rights holder.
What to take from it
- Verification beats generation. The agents could produce readable code all day. What made the project work was an automated test that returned only yes or no.
- Match the toolchain. Using the original compiler turned a fuzzy comparison into a strict one.
- Scale was parallel and large. Seventeen agents and several hundred billion tokens is not a weekend experiment, whatever the blog-post tone suggests.
- The legal side did not move at the speed of the tooling. The technical feat took three months. The takedowns arrived without much trouble.
The tidy lesson is that AI coding gets reliable when you build something that can say no. The less tidy one is that a technique this effective at reconstructing old commercial software invites exactly the attention it received.