A from-scratch reimplementation of Minecraft Beta 1.7.3 in Zig, using SDL3 and OpenGL 3.3. Client and dedicated server, both speaking the b1.7.3 protocol (version 14).
[!NOTE] The goal is a standalone b1.7.3 you can actually play: same behavior, same world out of the same seed, same packets on the wire. One native binary, and nothing beyond b1.7.3.
[!IMPORTANT] Work in progress. Most of the game is playable, so what's left is the fine detail. Anything that behaves differently than it does in the real b1.7.3 counts as a bug: terrain, block or mob behavior, a sound, a wrong pixel somewhere. If you spot one, open an issue with what you did and what the original does instead.
mdmrk.github.io/rosebed runs the client on WebAssembly. Worlds are saved in browser storage. Needs WebGL2.
Or download a build, each archive has both binaries, rosebed and rosebed-server:
| Platform | Release | Nightly |
|---|---|---|
| Linux x86_64 | tar.gz | tar.gz |
| Windows x86_64 | zip | zip |
| macOS aarch64 | tar.gz | tar.gz |
| Web wasm32 | tar.gz | tar.gz |
Everything is on the releases page. Nightly assets are rebuilt from the latest commit and replaced in place.
rosebed-server [--port 25565] [--world world] [--seed <n>] [--ticks <n>]
Requires Zig 0.16.0. SDL3 and the GL bindings come from the package manager, nothing else to install.
zig build fetch-assets # once, before anything else
zig build -Doptimize=ReleaseFast # binaries into zig-out/bin
zig build # debug build
zig build run # build and run the client
zig build run-server # build and run the dedicated server
zig build test # run the unit tests
Assets aren't in the repo, so fetch-assets has to run first. It downloads the official b1.7.3 client jar, checks its SHA-1 and unpacks it: textures, lang files and short sounds into src/assets/ to be embedded into the binary, music and records into zig-out/bin/resources/.
Anything after -- is passed to the program: zig build run-server -- --port 25566 --world test.
Needs emscripten on PATH and a patched copy of the Zig stdlib:
lib_dir=$(zig env | sed -n 's/^ *\.lib_dir = "\(.*\)",$/\1/p')
cp -r "$lib_dir" ziglib
chmod -R u+w ziglib
patch -p1 -d ziglib < .github/zig-emscripten.patch
zig build -Dtarget=wasm32-emscripten -Doptimize=ReleaseFast \
--sysroot "$(em-config CACHE)/sysroot" --zig-lib-dir ziglib
Output is a static site in zig-out/www. Serve it over HTTP, file:// won't work.
GPLv3. See LICENSE. Not affiliated with or endorsed by Mojang or Microsoft.
397 commits
Zig
99.5%
A from-scratch reimplementation of Minecraft Beta 1.7.3 in Zig, using SDL3 and OpenGL 3.3. Client and dedicated server, both speaking the b1.7.3 protocol (version 14).
[!NOTE] The goal is a standalone b1.7.3 you can actually play: same behavior, same world out of the same seed, same packets on the wire. One native binary, and nothing beyond b1.7.3.
[!IMPORTANT] Work in progress. Most of the game is playable, so what's left is the fine detail. Anything that behaves differently than it does in the real b1.7.3 counts as a bug: terrain, block or mob behavior, a sound, a wrong pixel somewhere. If you spot one, open an issue with what you did and what the original does instead.
mdmrk.github.io/rosebed runs the client on WebAssembly. Worlds are saved in browser storage. Needs WebGL2.
Or download a build, each archive has both binaries, rosebed and rosebed-server:
| Platform | Release | Nightly |
|---|---|---|
| Linux x86_64 | tar.gz | tar.gz |
| Windows x86_64 | zip | zip |
| macOS aarch64 | tar.gz | tar.gz |
| Web wasm32 | tar.gz | tar.gz |
Everything is on the releases page. Nightly assets are rebuilt from the latest commit and replaced in place.
rosebed-server [--port 25565] [--world world] [--seed <n>] [--ticks <n>]
Requires Zig 0.16.0. SDL3 and the GL bindings come from the package manager, nothing else to install.
zig build fetch-assets # once, before anything else
zig build -Doptimize=ReleaseFast # binaries into zig-out/bin
zig build # debug build
zig build run # build and run the client
zig build run-server # build and run the dedicated server
zig build test # run the unit tests
Assets aren't in the repo, so fetch-assets has to run first. It downloads the official b1.7.3 client jar, checks its SHA-1 and unpacks it: textures, lang files and short sounds into src/assets/ to be embedded into the binary, music and records into zig-out/bin/resources/.
Anything after -- is passed to the program: zig build run-server -- --port 25566 --world test.
Needs emscripten on PATH and a patched copy of the Zig stdlib:
lib_dir=$(zig env | sed -n 's/^ *\.lib_dir = "\(.*\)",$/\1/p')
cp -r "$lib_dir" ziglib
chmod -R u+w ziglib
patch -p1 -d ziglib < .github/zig-emscripten.patch
zig build -Dtarget=wasm32-emscripten -Doptimize=ReleaseFast \
--sysroot "$(em-config CACHE)/sysroot" --zig-lib-dir ziglib
Output is a static site in zig-out/www. Serve it over HTTP, file:// won't work.
GPLv3. See LICENSE. Not affiliated with or endorsed by Mojang or Microsoft.
397 commits
Zig
99.5%