# Shaped parts

Beyond whole blocks, Voxyl has two families of shaped parts. They are the widest gap between a
build that looks like blocks and one that looks like architecture: true roof slopes, thin
relief, sideways stairs, columns with capitals, arches, railings and light fixtures that are not
cubes. They also come with a catch, so read the section on when to use them first.

## What there is

`describe_shapes` lists every shape; with a shape id it lists the slots. Two families:

- **Microblocks** (Forge Microblocks): thin pieces on an 8 by 8 by 8 grid inside a cell, several
  to a cell, each of its own material. Covers (1/8 thick), panels (2/8), slabs (4/8) and their
  hollow versions; strips, posts and pillars along an edge; nooks, corners and notches. Slots
  name the side or edge the part sits on (`"north"`, `"down-north-west"`, `"center-y"`).
- **Architecture shapes** (ArchitectureCraft): one per cell, in one of 24 orientations. Roof
  tiles, corners, ridges, valleys and overhangs; slopes and stairs (including sideways ones);
  cylinders, spheres, pillars, posts and poles; classical pieces (capitals, triglyphs,
  architraves, cornices); arches; balustrades and banisters.

A palette entry says which: `palette_edit` with `shape: "roof_tile"` (or `"face2"`, `"arch_d2"`,
...) makes that role place that part, and a block is still chosen separately, so the material
stays swappable like any other. A shape replaces a block's own model with its plain shape, so
use shapes for architectural pieces, not for lanterns or bars ([details.md](details.md)).

## Where a part can go

**A cell holds one whole block, or parts. Never both.** This is how the format works (it is how
the mods store them), not something a tool can switch off, and it shapes how you plan:

- A part cannot be added to a cell that already holds a whole block. `place` turns it down as
  `block_in_cell` (the cell is full), and `occupied: "replace"` swaps the block for the part:
  the block is gone.
- So shaped detail on a wall goes in the **air cell in front of the wall**, not in the wall. A
  wall of full blocks stays a wall; a trim strip, a cover, a panel, a cornice or a roof tile
  sits in the empty cell beside it, against the wall (`slot: "south"` for a part against a
  wall to its south). Detail that needs the wall's own cell means a wall that is a cell
  thinner in that spot, with the part in the cell it freed.
- Microblocks share a cell with each other (a frame and a pane, a strip and a cover). An
  architecture shape takes its whole cell to itself, in one of 24 orientations.
- `fill` sets every cell it covers, so panelling a wall with `fill` replaces what stands on it:
  ladders, rails, catwalk cells. Pass `occupied: "keep"` to fill only the empty cells, and read
  `replaced` in the result, which names the roles that lost cells.
- An architecture shape with no `up` and `facing` (or `slot`) is not placed. `place` lists it
  in `rejected` and says so in `problems`: read `problems` after a call, and check
  `changed` is not 0.

Plan this per cell before a long run: which cells stay air, which hold the part, and what must
not be overwritten. `faces` lists the flat faces of a region (outward side and the cells whose
face it is), so the air cell in front of a wall is its `box` moved one step along `facing`.
`shape_sheet` shows a shape in every orientation, so you can pick `up` and `facing` by eye
([below](#looking-at-them)).

## They are mods: when to use them

Shaped parts only exist in a game that has the mods installed. Voxyl writes them as real
Forge Microblocks and ArchitectureCraft parts when it exports a Schematica `.schematic`
(Minecraft 1.7.10, as in GT New Horizons). A Sponge `.schem` (modern Minecraft: WorldEdit,
Litematica) has no place for them and **leaves them out**. As far as we could find, there is no
ArchitectureCraft for modern Minecraft (it exists for 1.7.10 and 1.12.2; "Architecture
Extensions" is a different, newer mod), and Forge Multipart lives on as a library whose
microblocks are not the same mod. So treat shaped parts as a feature for builds going to an old
version or a modpack that has them, and do not assume the user can use them.

Use them like this:

1. **Check what is known.** `status` has a `shaped_parts` block. It says whether the user's
   imported libraries show ArchitectureCraft or Forge Microblocks, and whether this project
   already uses shaped parts. If either is true, the user is working where they exist: use them
   freely, and say in a line that you are.
2. **If nothing says so, ask once, before building.** Do not use them silently, and do not
   avoid them without telling the user what they would gain. Something like: "Shaped parts
   (true sloped roofs, thin trim, arches, sideways stairs, glowing fixtures) would make this
   look noticeably better, but they need the ArchitectureCraft or Forge Microblocks mods in
   the game you will load it into, and a modern `.schem` export leaves them out. May I use
   them?" One short question, with the trade-off in it.
3. **If the answer is no, or they do not know,** build with whole blocks: stairs, slabs,
   trapdoors, fences, walls, bars and carpet ([details.md](details.md)) get you a long way.
   Say that shaped parts are available if they change their mind. A role's shape applies to
   what is placed after you set it (cells already placed keep the form they were placed with),
   so keep the roles that might become shaped (roof, trim, columns) separate and easy to redo.
4. **If you cannot ask** (no one to answer), build with whole blocks and say what shaped parts
   would have added.

The user's first answer carries on for the rest of the chat. Do not ask twice.

## What they are for

- **Roofs.** Roof tiles, ridges, valleys and corners give a real pitch where stairs and slabs
  step ([roofs.md](roofs.md)). Overhang shapes give the eave its own profile.
- **Relief finer than a cell.** A cover or strip 1/8 proud is a trim line, a panel is a
  recessed or raised plate, a post or pillar is a rail or a mullion ([depth.md](depth.md)).
  Several to a cell, in different materials: a frame and a pane in one cell.
- **Curves and rounded forms.** Cylinders, half and quarter cylinders, spheres and arches make
  towers, tanks, domes, pipes and openings that cubes cannot.
- **Classical and decorative pieces.** Capitals, architraves and cornices finish a colonnade;
  balustrades and banisters make stair rails.
- **Light.** See below.

## Creative lighting

A part set to `glow` is a light source in the editor, and the glowing variant of an
ArchitectureCraft shape exports as a self-lit shape, so a fixture does not have to be a block
with a lantern on it. Worth trying when a build wants light in a shape:

- A **strip or cover** along the underside of a cornice, a ceiling edge or a handrail: a cove
  light that washes the surface below it and shows no source.
- A **pillar, post or pole** as a glowing tube or lamp standard; a **cylinder** or **sphere** as
  a lamp, a reactor core, a tank of something luminous.
- An **arch** or **slope** with a glow, as a lit canopy, a skylight or a glowing ramp edge.
- A **hollow cover** or **panel** as a lit sign face or a display.

Keep the same discipline as other light ([details.md](details.md)): a few deliberate sources,
a hierarchy, the rest dim. And mind the limit: in the editor any part with `glow` lights its
surroundings, but in the game an ArchitectureCraft shape has a glowing variant, while a
microblock gives off only as much light as its material does, so for microblock lights choose a
material that emits (`describe_block` says which blocks do).

## Looking at them

- `shape_sheet {shape}` draws one shape in every orientation, each tile labelled with the `up`
  and `facing` that place it (and the slot name), so you do not have to guess an orientation
  and look. Do this before placing a roof piece, a stair, an arch or a banister you have not
  used. Microblock shapes show each slot.
- Shaped parts are thin, so look close: `capture` with `where` round the detail and a larger
  `size`, and a low `elevation` for relief.
- `inspect` `summary` lists parts apart from whole blocks, by shape and count.
- `export_schematic` reports what it could not write. Run it with `dry_run` before telling a
  user the build will load, and name the format you checked.
