Skip to content

Installation

Before installing DownDraft Engine, ensure you have the following tools installed:

DownDraft uses Bun as its package manager and default JS runtime — games execute against the native platform library via runtime-adapted FFI (bun:ffi under Bun). Node+tsx (koffi) and Deno (Deno.dlopen) are also supported hosts via draft dev --runtime=node|deno and as packaged runtimes via draft release --runtime=node|deno (linux), but Bun is required regardless for dependency installation (bun.lock), bun test, and as the packager’s own host.

Terminal window
curl -fsSL https://bun.sh/install | bash

Rust is only needed if you’re building the platform or audio native libraries from source.

Terminal window
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh
Terminal window
git clone https://github.com/knackstedt/downdraft-engine.git
cd downdraft-engine
Terminal window
bun install

This installs all workspace dependencies via Bun workspaces. Games are separate repos — if you develop a game alongside the engine under games/, run bun run link:games to link @downdraft/* packages into each game’s node_modules.

Scaffold a game and run it to verify everything works:

Terminal window
draft new my-game
cd my-game
draft dev

This launches the game on the native runtime via its src/native-entry.ts entrypoint. You should see a native window with the WebGPU-rendered scene and devtools overlay.

Terminal window
cd <game-directory> && draft dev