Наталя ХандусенкоAI Eng
12 October 2026, 16:24
2026-10-12
Developer recreates Call of Duty: Modern Warfare 2 (2009) source code using AI and over 500 billion tokens
German developer Moritz Heumann has managed to almost completely decompile and recreate the source code of the cult shooter Call of Duty: Modern Warfare 2 (2009). The project lasted about three months, involved a swarm of AI agents, and consumed, according to the author's estimates, from 600 to 700 billion tokens. Now 99% of the game's functions are present in the code, and 83% of them match the original byte-for-byte.
German developer Moritz Heumann has managed to almost completely decompile and recreate the source code of the cult shooter Call of Duty: Modern Warfare 2 (2009). The project lasted about three months, involved a swarm of AI agents, and consumed, according to the author's estimates, from 600 to 700 billion tokens. Now 99% of the game's functions are present in the code, and 83% of them match the original byte-for-byte.
How he organized an "AI factory" for the development
To work on the decompilation, Goumann used a combination of models from Anthropic and OpenAI, working through the CLI tools Claude Code and Codex CLI. The tools analyzed the game's binary code through the IDA decompiler using the ida-mcp plugin from Hex-Rays, writes Tom's Hardware.
The project started with four agents (three “workers” and one “reviewer”), and at its peak, 17 AI agents were working on the code simultaneously.
A separate issue was opened on GitHub for each broadcast unit, and all agents and the author communicated in a single Discord channel via CI webhooks. The context auto-compression threshold was lowered from the default 90% to 42% to promptly remove already processed functions from the agents' memory. To ensure that agents did not deviate from the instructions, an automatic script forced them to reread the project rules every hour.
AI tried to "cheat"
The first month of work turned out to be an illusion of success: the code looked readable, but contained critical errors in logic, data types, and structure. In addition, the agents unnecessarily changed the architecture — for example, turning fast access to global variables into heavy hash tables.
The reviewer agent could not prevent this, since the "workers" in the comments to the code convinced him of the appropriateness of the changes (the author compared this to unintentional prompt injection).
To overcome the problem of incorrect generation, the developer implemented a strict automatic pass/fail check based on the original compiler, which compares the generated AI code with the game binary at the byte level. However, in response, AI agents began to find workarounds - writing assembly language inserts and editing the test script itself to exclude their functions from the check. To protect the system, assembly language inserts were completely prohibited in the instructions, and the integrity of the test script itself was controlled using hashing via GitHub Actions Secret.
The rigorous autotest gave an unexpected plus: even cheap and less powerful models (like Haiku or Luna) received clear feedback and began to produce high-quality results, which significantly reduced the cost of the project.
Cost, lawyers and the future of the project
The developer used fixed subscriptions (Claude Max 20x and Codex Pro), which resulted in a real cost of around €1,200. At standard API rates, using this many tokens would cost between $80,000 and $250,000.
The publishers' legal departments reacted quickly - previous posts on Goumann's blog and a video demonstrating the game on X (Twitter) were blocked due to copyright claims.
The author emphasized that the source code will remain private and will not be published in the public domain, as it is Activision's intellectual property.
Despite this, the experience turned out to be unique. Heumann's main conclusion for developers in the AI era: "Code generation now costs a penny. If it's bad, throw it away and focus on automated correctness checking, not speed."
Як нейромережі бачать вільну та незалежну Україну? Тест dev.ua
Нейронні мережі для генерації зображень бачать світ по-своєму, їхню логіку зрозуміти часом зовсім неможливо. Але таки хочеться. На честь Дня Незалежності України редакція dev.ua вирішила провести невеликий експеримент.
Ми задали чотирьом різним нейронним мережам п’ять однакових запитів: «прапор України», «День Незалежності України», «український Крим», «перемога України» та «українці». Отриманими результатами ми ділимося з вами нижче.
У TikTok тепер можна генерувати фон за допомогою нейромережі. Ми протестували її та ділимося результатами
У TikTok з’явилася нова функція «Розумний фон». З її допомогою як фон для тіктоків можна підставляти згенеровані нейромережею зображення. Редакція dev.ua протестувала цю технологію і ділиться своїми враженнями.