Element · run

wall

A masonry wall standing on a tile edge: cut stone, fieldstone, brick or regular brick, laid in courses with real joints, its top at the official wall-top level ($wallHeight, 33.1dmm). On a tile edge it always stands inside the tile, its outer face flush with the edge, so walls on neighbouring tiles line up.

Floors are their own elements, flagstones and planks; walls stand on them. Doors, windows and hatches are not built yet.

Styles
cut stone, fieldstone, brick, regular brick
Sizes
full height (33.1dmm) by default, 7dmm thick
Printing
no supports; no stone stands more than 0.45 mm proud of the one under it
In the library
tiles/walls/, floors/1x1-floor-stone-wall
Words used on this page
spine
The line a wall follows in plan. It is the wall's outer face; the wall's thickness extends into the tile.
course
One horizontal row of stones.
joint
The seam between two stones. It reads as a dark groove that holds a wash.
quoin
The corner stones. Two runs take turns passing through the corner, course by course.
coping
What tops a drystone wall: loose stones perched on top, or stones set on edge.
opening
A door, window or floor hatch, with its surround (jambs plus an arch or lintel).
leaf
What fills an opening: a door, shutters, bars, a trapdoor or a portcullis.
A one-square tile with a cut-stone wall turning a corner along the north and west edges, grass in front
lib:tiles/walls/1x1-wall-stone-corner.dtile, built by the program today.

What it looks like

A wall is built stone by stone. Courses run level, joints never line up from one course to the next, and each stone sits a little proud or a little back, so it takes its own tone under a drybrush. The ends of a wall show the ends of its stones, with the joints set in behind them. The top is flat and shows the tops of the stones, not a smooth cap.

Families

FamilyWhat it isWritten
Cut stoneLong, chipped blocks in irregular courses, the classic dungeon wall. Four surface presets: chipped (default), worn, hewn, dressed.wall style=cut-stone
FieldstoneDrystone: flat, rounded natural stones packed tight with no mortar, small rough chips filling the gaps. Topped with perched stones or a row of stones on edge.wall style=fieldstone
BrickSmall worn bricks with a few missing and spalled.wall style=brick
Regular brickUniform bricks in dead-level running bond, half a brick offset per course.wall style=regular-brick
Stone floorDressed slabs gridding the ground, one per square by default, some cracked, spalled or missing.flagstones
Drystone floorFlagstones: a fieldstone wall laid on its side.flagstones style=fieldstone
Chipped cut-stone wall along the north edge of a grassy tile
Cut stone, chipped: lib:tiles/walls/1x1-wall-stone.dtile.
Regular brick wall in running bond with battlements, on bare dirt
Regular brick with top=battlements: demo/wall-battlements.dtile.
Drystone flagstone floor with a fieldstone wall standing on it
A fieldstone wall with coping=on-edge on a flagstones style=fieldstone: demo/flagstones-fieldstone.dtile.
A low ruined cut-stone wall with rubble showing along its broken top
ruin="70%": a broken top with rubble showing: demo/wall-ruins.dtile.

Using it in a tile

A wall must have at= a line: a tile edge, an edge path (two edges make a corner), or a drawn line:

dharmatiles version="1.0.0"

use "parts/grass" lawn

tile size="1x1" seed=62 {
    stack {
        base
        dirt
        wall at="north west" style=cut-stone {
            height full                 // up to the wall-top level, $wallHeight
            thickness "7dmm"
        }
        lawn                            // grows up to the wall's foot
    }
}

The styles: style=cut-stone (the default), fieldstone (drystone, no mortar), brick and regular-brick. Each sets its own stone sizes and finish; stones, joints and edges adjust them:

wall at=north style=fieldstone {
    stones height="2.2dmm .. 5.2dmm" length="5dmm .. 16dmm" texture=worn
    coping on-edge                      // what tops a drystone wall
}

Along a drawn line, side=left, right or centre says which side of the line the wall stands, as you walk it: left puts the body to the left of the direction the line is drawn, with the line as its outer face; right puts it to the right; centre (the default) centres it on the line. The wall follows the line as the tile has it, wobble included, so a new tile seed moves the wall with the line.

line lane wobble="6dmm" { through "(0sq, 1.5sq)" "(0.85sq, 1.22sq)" "(1.35sq, 0.62sq)" "(2sq, 0.5sq)" }
stack {
    dirt
    wall at=lane side=left style=cut-stone
}

The line is cut into straight runs that stray no more than 0.35dmm from it, and a run turns at each vertex. A left turn of exactly a right angle is a corner like an edge path's, the two runs taking turns passing through it. Any other turn is a bend: the two runs overlap, the one on the outside of the turn running on past the vertex so its face is whole. A wall turns at most 150 degrees at one point. The free ends of an open line are textured ends; a line that returns to its first point makes a ring. A line that meets a tile edge ends flush with it when it meets it square, and otherwise runs on past it and is cut at the tile edge. Library: lib:tiles/walls/2x2-wall-curve.dtile. Give a wall a seed= of its own to pin its look while the rest of the tile changes; the library walls do not, so they follow the tile seed.

Reference

Kind
a run: built along a tile edge or a drawn line
Place
at= region, line; side=
Must have
at=
Built
yes

Controls

ControlTakesDefaultWhat it does
stylewordcut-stonehow stones are made and laid
fieldstone
drystone fieldstone
cut-stone
dressed ashlar
brick
irregular brick
regular-brick
uniform brick in running bond
heightlength (dmm), 6 to 200fullheight above what it stands on
full
up to the wall-top level
low
half the wall top (provisional)
thicknesslength (dmm), 2 to 407dmmwall thickness
stonesgroup—stone size
stones heightlength (dmm), 1 to 40, or a range, or a weighted range—course height
stones lengthlength (dmm), 2 to 80, or a range, or a weighted range—stone length along the wall
stones textureword—surface finish of each stone
chipped
chipped cut stone (Hirst Arts m50)
worn
soft, weathered
hewn
rough-hewn all over
dressed
near-smooth ashlar, crisp edges
jointsgroup—the gaps between stones
joints widthlength (dmm), 0 to 3—mortar gap
joints depthlength (dmm), 0 to 5—how deep the gaps between stones look
edgesgroup—the stone corners
edges roundinglength (dmm), 0 to 5, or a range, or a weighted range—how worn the stone corners are
copingword—what tops a drystone wall
loose
loose stones perched on top
on-edge
stones set on edge
bondword—random courses, or brick-style offsets
irregular
random courses and bays
running
uniform courses, half-unit offsets
ruinpercent, 0% to 100%—how much has fallen
topword—castle crenellations
flat
a flat top
battlements
merlons and crenels

In the library

Generated from dharmatiles elements wall by cargo xtask docs.

Floors

Sizes and levels

Edges and joining tiles

Rules

What this element always does. A change to one of these is a change to the element.

Printing and painting

The full printing rules are on the printing page.

How it is made

Step by step

A wall is laid stone by stone. Its line is split into segments, then courses and bays, and every cell becomes one stone, each its own solid. Mortared styles stand on a recessed core, so the joints read as real gaps; drystone has no core and is filled with rubble behind.

What the program does, in order:

  1. Spine: the line the wall follows (at=): its outer face, with the wall's body to its left; on a tile edge, inside the tile.
  2. Layout: courses (rows) × bays (stones along a row), with quoins alternating at corners and ends, make the cells; top battlements and ruin edit the cells.
  3. Stones: every cell becomes one unit: a dressed block (cut stone, brick, regular brick) or a fieldstone; its finish (texture) is chipped, worn, hewn or dressed.
  4. Core and joints: mortared styles stand on a recessed core and the joints are reveals onto it; drystone has no core, and rough rubble fills behind the face.
  5. Printability: no stone stands more than 0.45 mm proud of the one under it, and the joint width never shrinks below what prints; both stay fixed when the wall is scaled.
  6. Fit: the wall is the union of its stones, cut to the tile (so it butts its neighbour), and its footprint is stamped so grass grows round it.

The code: crates/dt-elements/src/wall/.

All the families share one chassis, CutStoneWall in src/dharmatiles/walls/masonry.py (line 512). A family changes the stone, not the layout.

  1. Layout. _layout (line 286) splits the spine into straight segments and corner cells, samples course heights so the top lands exactly at the wall top, then cuts each course into stones, rejecting any joint that lines up with one in the course below. Corners alternate per course. Openings, battlements and ruin states edit this list of cells (_apply_openings line 893, _crenellate line 742, _ruin_cells line 1199).
  2. Stones. Each cell becomes one stone. Cut stone and brick are exact rounded blocks with chipped edges and the common stone relief (the same finish as the rocks). Fieldstone (walls/fieldstone.py, line 177) works the other way round: it draws the crack network first, with each crack shared by the stones on both sides, then morphs a pebble into each region, so neighbouring stones fit like a real drystone wall.
  3. Core and hearting. Mortared walls have a hidden core set back from every face, which shows as the mortar. Drystone walls have no core; about a thousand small rough chips fill the inside (_hearting_parts, line 1246).
  4. Assembly. Stones, core and surrounds are unioned into one solid. separate_pinches nudges apart points where two stones only just touch, so the STL stays watertight (src/dharmatiles/stone/solidify.py:42), and the wall is clipped to the tile (line 1564). Slots are one boolean cut out of the finished wall (_cut_slots, line 848). The footprint is stamped into the ground so grass steers around it.

A floor is the same chassis laid flat: the wall's height axis becomes the second plan axis, courses become rows of slabs or boards, and each piece takes its top from the floor's band (crates/dt-elements/src/floor.rs).

Texture presets
PresetChip (mm)Rounding (mm)Relief (mm)Read
chipped0.550.220.07Chipped cut stone (Hirst Arts m50)
worn0.300.600.10Soft, weathered
hewn0.800.150.16Rough-hewn all over
dressed0.150.120.03Near-smooth ashlar, crisp edges

_TEXTURES, walls/masonry.py:108.

Seen from the language

The guide pages that use wall: Worked tiles.