Minecraft in its most primitive form has just landed on hardware Notch couldn't have dreamed of back in 2009. The rdgeneric project, published on GitHub by developer pragyaangaur, recreates version rd-132211, the first public release of Minecraft from May 13, 2009, as a single C source file that compiles and runs on six completely different platforms, from a text terminal to a bare x86 processor with no operating system at all.

One game core, six platforms

The project's author describes it as an implementation inspired by doomgeneric, a well-known approach of writing a game engine with no operating system dependencies and no dynamic memory allocation. Thanks to that, the same code in src/rd.c only needs to be compiled against a specific framebuffer and keyboard handling to run almost anywhere.

  • Terminal: rendering with block characters, with mouse support
  • Telnet: a shared, common world for multiple connections at once
  • Browser: a 20 KB WebAssembly module that runs fully offline
  • PDF file: a JavaScript engine run in Chrome using 120 text fields
  • Bare x86 processor: VGA mode 13h, PS/2 support, boots without an operating system
  • Raspberry Pi Pico, Pico 2, and Game Boy Advance microcontrollers (compilation confirmed, hardware testing not confirmed)

Gameplay is based on raycasting, one ray per pixel, similar to the famous Minecraft 4K, the minimalist version of the game from 2010 written for the Java4K competition. The world is procedurally generated, and the physics and lighting reproduce a small fragment of the mechanics known from today's Minecraft Java Edition.

How small Minecraft can get

The compiled rdgeneric code weighs between 9 and 14 KB, depending on the target architecture. The version running inside a PDF file uses the wasm2js tool, which converts the WebAssembly module into plain JavaScript understood by the browser engine that displays the document. All platforms execute identical physics, with the world described by integers and the player's position by floating-point numbers, which ensures consistent game behavior whether you're running it on a brand new laptop or an emulated computer from the early '90s.

The project is released under the MIT license, meaning full freedom to modify and further develop the code within the community. The repository's README contains a demo GIF showing an identical walk through the same world simultaneously in the browser, terminal, PDF, and on bare x86, and the working web version can be launched directly from the author's GitHub Pages.

Why this matters to players

For the Minecraft community, used to updates adding new biomes, mobs and mechanics in subsequent versions of the game, rdgeneric is a reminder of what the starting point looked like: a game with no crafting, no mobs, and most blocks missing, where all that mattered was placing and removing six types of blocks in a procedurally generated world. It's exactly this version, rd-132211, that circulates online as a playable demo of Notch's original concept, before Minecraft gained a crafting system and the thousands of hours of content that today draw new audiences to the game, including on consoles and mobile devices.

Projects like rdgeneric regularly top the popularity charts on GitHub and Hacker News precisely because they combine nostalgia for the game's first version with pure engineering curiosity: how much can you squeeze out of a single C file to run it on hardware whose power is measured in megahertz, not gigahertz. For developers interested in retro computing and embedded systems, it's a concrete, working example of how to write code portable across wildly different platforms without a single line of operating system specific conditionals.

Sources