Data‑first interactive fiction engine and authoring DSL in Rust.
I wanted to learn Rust and thought an 80s‑style parser adventure (think Zork) would be the perfect project. A small game prototype quickly snowballed into a data‑driven engine, a friendly DSL, and tooling to build real adventures.
Amble is a data‑first engine that loads worlds from compiled WorldDef data (world.ron or worlds/*.ron), plus a DSL and compiler that make worldbuilding fast and readable. The repo includes developer tools and a fully playable demo you can run immediately.
The Amble DSL is designed to read like plain English while staying precise and composable.
- Start with
amble_script/docs/dsl_creator_handbook.mdfor the language tour. - For rich editing, see the Zed Amble extension - powered by tree-sitter-amble
- Download the appropriate ZIP from Releases.
- Extract and run
amble_engine(useamble_engine.exeon Windows). - Type
helpin the game REPL for commands. Saves go tosaved_games/<world>/.
- Install the latest stable Rust toolchain.
- Clone this repository and
cdinto it. - Run the engine with the bundled content:
cargo run -p amble_engine - Use
helpin the REPL; saves land insaved_games/<world>/.
- Explore the DSL guides in
amble_script/docs/—start withdsl_creator_handbook.md. - Compile the sample DSL to
world.ron:cargo run -p amble_script -- compile-dir amble_script/data/Amble --out-dir amble_engine/data(Use--out-world amble_engine/data/worlds/<slug>.ronto add multiple worlds.) - Launch the engine to test your changes:
cargo run -p amble_engine - Iterate with
amble_script lint …to catch missing references early.
amble_engine- loads world data fromworld.ronorworlds/*.ron(plus TOML configs for themes/scoring/help) or a saved state, then runs the gameamble_script- an intuitive, English-like language (DSL) for defining the game world, which compiles intoWorldDef(RON) used byamble_engineamble_data- world data model, shared betweenamble_engineandamble_script.xtask- automation helpers for builds, packaging, and the content pipeline
tree-sitter-amble- a tree-sitter parser / syntax highlighter for the amble_script DSLzed-amble-ext- a full-featured extension for the Zed editor with syntax highlighting and a language server (supports outlining, references / go-to-definition, symbol renaming, formatting, diagnostics, autocomplete -- development still ongoing.)
- Data-first design so stories live entirely in
.amble->world.ron(orworlds/*.ron) data, not code - Rooms with conditional description overlays that can adapt to world state and connections that can be conditional, hidden, locked, or remapped entirely during play
- Items support a variety of capabilities (like "ignite" or "smash" or "turn on") and interactions, and can be consumable; items can also be containers and nested to an arbitrary depth.
- NPCs supported with dialogue, trade options (via triggers), moods/states, and movement on either predetermined routes or randomly through a defined area
- Goals / Achievement system to help guide players to important objectives and mark progress
- Configurable point scoring system
- Customizable status effects
- In-game help system for players (built-in help for commands with customizable general help text.)
- WorldDef validation plus a placement pass that seeds initial room/NPC/item locations
- Thorough logging of game and engine events enabled throughout
- REPL-style parser with natural language verbs, synonyms, and DEV tools
- Powerful trigger/scheduler system for conditional, delayed, or repeating events
- Flexible flag model with sequence counters and derived logic helpers
- Themeable terminal UI with multiple palettes and optional styling
- Simple terminal markup allows additional styling for emphasis on top of the active theme (but also theme-aware)
- Save system (RON full game state snapshots) for restoring worlds mid-adventure
- Comprehensive test suite and CLI for fast iteration
- Any ideas / comments or contributions welcome!
- I check the repo Issues and Discussions regularly.
