0xreversed/with.ai
Games and modsPartialSource available
Target: Colin McRae Rally 2.0 (PC, 2000)

Rebuilt every function of Colin McRae Rally 2.0 as C++ with Claude and Codex agents

Colin McRae Rally 2.0 (PC, 2000): Every function of a 2000 rally game rebuilt in C++.
Image: GitHub (pablocpas/CMR2Decomp)

What was done

pablocpas used Claude and Codex agents to write C++ for every function in the Colin McRae Rally 2.0 PC executable, most of it byte-identical, and the rebuilt game is mostly playable.

pablocpas is rebuilding Colin McRae Rally 2.0 (PC, Win32) as C++ source that the original Visual C++ 6.0 compiler turns into the same code. The README says most of the source, tooling and documentation was written by AI coding agents, Anthropic's Claude and OpenAI's Codex, under human direction, with correctness resting on automated checks.

How it was done

Every function is compared byte for byte with the original executable using reccmp, and a byte audit after relocation is the authoritative measure. Differential tests run original and rebuilt code side by side under Unicorn with the same inputs and compare memory and calls. A matching loop script compiles one translation unit, diffs it and checks the whole unit in about a second, and a CLAUDE.md file records the fixes that worked. The project also tries semantics-preserving renames of local variables, because the old compiler breaks stack-slot ties by name.

Results

The README reports C++ source for all 3,364 game functions identified in the executable. Most compile to byte-identical code, and the rest differ mainly in instruction scheduling and register allocation. The rebuilt executable boots, runs the menus and drives rallies on the original game data under Wine, with some bugs. Next goals are finishing the matches, an SDL3 port and optional modern upgrades. No game data is included.