Skip to content

Worlds, neighborhoods and inputs

A modern project contains exactly one world declaration across its files:

world {
dimensions 3;
cell Cube;
neighborhood VonNeumann;
}

Studio currently presents a three-dimensional Cube lattice. Z is vertical. The world declaration describes the lattice; it does not fill it with cells. Paint cells, build a world recipe, or open a published simulation.

The default VonNeumann neighborhood supplies axial neighbors. Custom neighborhoods list integer offsets explicitly:

neighborhood Rise {
offset [0, 0, 1];
}

Select a neighborhood with neighbors[Heat using Rise] or expand with Cell using Rise. The compiler resolves the reference directly; no needs declaration is required. Omitting using selects the world’s default. Directions such as +X, -Y and +Z are spatial operators; offsets determine which positions are reachable. Hidden cells in a Studio slice continue participating in neighborhood calculations.

Inputs are global scalar controls that the host can change between simulation steps:

in wind_speed: Float<0.12> [0.0 1.0] ~1e-3;

The compiler preserves input bounds in .sole. Both runtime backends check the default when loading the module and check every input change before storing it. Brackets include an endpoint; parentheses exclude it. Rejected changes leave the previous value intact. Non-finite floating-point inputs (NaN and infinities) are rejected. Integer comparisons retain their full precision, and floating-point endpoints use the input’s selected storage precision.

Recompile older .sole files to recover declared input bounds. Legacy files with bounds: null still load, but only scalar type and finite-value checks are possible.

Studio does not currently expose mutable runtime-input controls. The source defaults are used by its current worker continuation path. Host integrations that change inputs must preserve those values when implementing restoration or remote execution.

Multiple resolutions and alternative lattice geometries are design topics, not features enabled by the examples on this page.

Hyle Astro