terrain-forge-api

Document the terrain-forge crate API for tile and procedural terrain generation.

Updated Dec 13, 2025
One-click install
npx skills add https://github.com/EliasVahlberg/saltglass-steppe --skill terrain-forge-api
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: terrain-forge-api
Source: https://github.com/EliasVahlberg/saltglass-steppe/tree/main/.kiro_snapshot_2026-04-04_1209/skills/terrain-forge-api
Command: npx skills add https://github.com/EliasVahlberg/saltglass-steppe --skill terrain-forge-api

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Provides a concise, practical API reference for the terrain-forge crate to reduce friction when implementing tile-based and procedural terrain generation, composing multi-step generators, and ensuring deterministic seeded outputs across the generation pipeline.

Core Features & Use Cases

  • Core type summaries for Tile, Cell, Grid, and Rng to standardize map and cell interactions.
  • Algorithm registry and direct instantiation guidance for algorithms like BSP, cellular automata, drunkard walk, WFC, and region connectors.
  • Composition patterns including sequential pipelines, layered generators, and ops pipelines for combining algorithms and effects.
  • Utilities for noise sampling, spatial analysis, graph and Delaunay analysis, prefab libraries and serialization, constraint validation, and deterministic seeding.
  • Practical use case: assemble a seeded pipeline that creates rooms via BSP, refines them with cellular automata, places prefabs, validates connectivity, and extracts semantic markers for game placement.

Quick Start

Ask for step-by-step API guidance to compose a seeded pipeline that generates a dungeon with rooms, applies erosion, and inserts prefab treasure rooms.

Frequently Asked Questions about terrain-forge-api

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I compose a procedural terrain generation pipeline in Rust?

To compose procedural terrain generation pipelines in Rust, use sequential pipelines and layered generators to combine algorithms like BSP and cellular automata, then apply ops pipelines for effects. This multi-step composition standardizes map interactions and ensures deterministic seeded outputs.

Can I combine different algorithms like BSP and WFC for tile-based terrain in Rust?

Yes, you can combine algorithms like BSP, WFC, and drunkard walk for tile-based terrain in Rust. The algorithm registry and direct instantiation guidance support composing these algorithms sequentially or in layered generators to refine generated maps.

How do I ensure deterministic seeded outputs across a terrain generation pipeline?

To ensure deterministic seeded outputs across a terrain generation pipeline, use the provided deterministic seeding guidance and Rng type. This maintains consistent generation results when composing multi-step generators and applying spatial constraints.

How do I serialize and place prefabs in a generated terrain map?

To serialize and place prefabs in a generated terrain map, use the prefab library utilities and serialization examples. This allows inserting prefab structures like treasure rooms into generated maps and extracting semantic markers for game placement.

How do I validate spatial constraints and connectivity in procedurally generated terrain?

To validate spatial constraints and connectivity in procedurally generated terrain, use the spatial analysis, graph and Delaunay analysis, and constraint validation utilities. These functions verify that generated maps meet required connectivity and spatial rules.