Skip to main content

Procedural Recipes

Procedural Recipes are Eldiron's shared assets for deterministic procedural visuals. A recipe can describe height fields, patterns, colors, renderer materials, architectural features, or reusable 2D shape coverage. Its canonical representation is a small, human-readable .recipe document, regardless of whether it is edited visually in Eldiron Creator, as project text, or with an external editor.

The goal is one procedural foundation with small adapters for different consumers. Tiles, Avatar wearables, headgear, and future UI or geometry systems should reuse the same fields and materials instead of developing separate pattern languages.

Recipe document
fields, patterns, shapes, colors, materials
|
consumer-specific adapter
|
Tile / Avatar / future consumer

Current support

AreaStatusWhat recipes provide
TilesStableImages, coordinated multi-tile coverage, height, surface materials, collision metadata, and programmable additive/subtractive Box geometry.
MaterialsStableReusable color, roughness, metallic, opacity, emission, and micro-normal definitions.
Avatar wearablesInitial supportRecipe materials projected through semantic Avatar marker channels in all eight directions.
Avatar headgearExperimentalAn SDF silhouette fitted to the head bounds and colored by a reusable material.
General SDF coverageExperimentalResolution-independent 2D primitives and boolean operations.
General geometryInitial supportPlacement-local Box primitives, additive/subtractive composition, repetition, and per-node surfaces in the Tile/map adapter.
Brushes, stamps, UI, and particlesPlannedIntended consumers of the shared core; no public binding contract yet.
Complete recipe-defined AvatarsPlannedA later extension; existing frame-based Avatars remain the current system.
note

This chapter documents implemented behavior separately from planned architecture. Experimental SDF support is deliberately small and may evolve before v1.

Design principles

  • Recipes are deterministic, bounded, and side-effect free.
  • A reusable recipe describes procedural visual data, not gameplay behavior.
  • Consumers own placement, dimensions, masks, transforms, and other context.
  • Materials and shapes remain independent so one silhouette can use many finishes.
  • Project palette choices remain available without coupling recipes to a specific ruleset.
  • Existing Tile and Material recipes remain the compatibility base as new consumers are added.

Authoring surfaces

Recipes are not tied to Eldiron Source. They belong to the project or ruleset recipe catalog and may be consumed by any compatible Eldiron system.

  • Eldiron Creator is the intended primary visual authoring surface. Recipe assets will be editable from the project tree with live previews and a canonical text view as integration is completed.
  • Text projects can store .recipe documents directly in their recipe catalog. Eldiron Source currently provides this workflow.
  • The command-line tool validates and renders the same canonical documents, making it useful for previews, automation, and external-editor workflows.

The visual editor and text representation should describe the same recipe program. Moving between them must not create a separate Creator-only or Source-only format.

In this chapter

The crate README remains the exhaustive low-level language reference during this documentation migration. This chapter is the user-facing guide and will absorb that reference incrementally.