Case study · Private

Rengy

A 2D game engine with a GUI editor, written in Rust

Rengy is built to make one specific metroidvania-style game, and to be installed and used by two other game authors, who work in Unity and Godot, don't write Rust and won't install a Rust toolchain. It has an editor for building rooms, a scripting language of its own, and an export that produces a folder you can zip and send, for the system the editor runs on.

Rengy is private and closed. There is no download, no release and no date. This page exists to show how it is built and what it can do.

Role
Built solo
Language
Rust
Targets
Windows, Linux, Android
Status
Private, closed

The editor

One window for building, playing and exporting. A room is a tree of nodes; the hierarchy, assets and inspector sit around a viewport that can run the game in place.

The Rengy editor with a lit room open and playing through its camera. A pixel-art room holds a character, a copper lamp, a cone of cold moonlight and a small machine, with shadows cast by the platforms. The Hierarchy lists the room's nodes on the left, the Assets panel is below the viewport, and the Inspector on the right has nothing selected.

Decision record

The plan locks its big choices early and records why. These are the ones that shape everything else.

Language

Rust

A deliberately simplified style: arena and handle-based nodes instead of reference-counted graphs.

Graphics

wgpu

D3D12 on Windows, Vulkan on Linux and Android. One abstraction, each platform on its healthy path.

Editor UI

egui

Permanently. The editor is a tool, not a product with a design language to maintain.

Scene model

Scene graph with components

Not ECS. A node, its components and its children.

Scripting

Rengy Script, two backends

One first-party language over one checked AST: transpiled to a hot-reloaded Rust dylib, or interpreted. A differential test holds the two to identical answers.

Targets

Windows, Linux, Android

Nothing else. No iOS, no macOS, no WebAssembly, no consoles.

No third-party VM

No Lua, Rhai or WASM

Game logic is Rust or Rengy Script. Nobody else’s language, nobody else’s VM.

Rengy Script

A script is a component, and its fields show up as rows in the Inspector. One language, one checked AST, two backends: transpile to Rust and hot-reload it as a dynamic library, or interpret it directly for an author with no Rust toolchain.

The two backends are held to identical answers by a differential test. That gate is the design. There is no bytecode VM, no garbage collector and no second type system.

The Code panel open on flicker.rgs, a Rengy Script component named Flicker whose loop function sets the intensity of the Light on its node from two sine waves. The lamp node is selected in the Hierarchy, and the Inspector shows the two fields the script declares, Brightness 1.00 and Dip 0.20.

What it does

An overview of what the engine runs today, by area. The full list, with the guides behind each line, is on rengy.splimter.com.

Editor

  • › Dock, stack and float panels; each project keeps its layout
  • › Play, pause and step inside the editor
  • › Run game through the same player an export ships
  • › Artifacts: save a node once, place copies with per-instance values

Scripting

  • › Scripts are components; their fields are Inspector rows
  • › Hooks, and await on a delay, a signal or an anneal
  • › Anneals and pulses along any of 45 curves
  • › Controls named as actions and bound to keys

Light and shadow

  • › Point, cone, directional, sprite and freeform lights
  • › Shadows from occluders and tiles, nothing baked
  • › Ambient light and light channels
  • › Normal maps generated in the editor

World

  • › Scenes as trees of nodes and components
  • › Sprites from sheets and framed panels
  • › Tilemaps with terrain and solid layers
  • › Drawn terrain, masks, cameras and parallax

Motion

  • › Character bodies, areas and triggers
  • › Sprite animation, keyframes and state machines
  • › Bones, joints and cutscenes
  • › Paths, navigation and forces

Effects

  • › Shader materials on sprites and lights
  • › Bloom and colour grades
  • › Particles, with forces, trails and materials
  • › Minimaps, monitors and clip rectangles

Sound

  • › Sounds positioned in the room
  • › Music and bus volumes
  • › Mixes and sound zones
  • › Music that reacts to the game

Interface

  • › Canvases and anchors that hold at any screen size
  • › Buttons, sliders, toggles, dropdowns and text fields
  • › Dialogs, menus, scrolling lists and drag and drop
  • › Localization, drawn in an exported game too

Shipping

  • › Export a game as a folder you can zip and send
  • › Levels played in order, with win and lose
  • › Saving and save slots
  • › A Console and debugging tools
The Rengy editor with the night sky node selected. The Inspector shows its Node settings and its Parallax and Sprite components, and the Assets panel lists three tile sheet pictures in the art folder.

Go deeper

Stack

RustwgpueguiRengy ScriptD3D12VulkanWindowsLinuxAndroid