Expand description
What a block needs beside it to stay — the pinned game’s
BlockState.canSurvive, as a table.
A wall torch on a glass pane, a lantern hung under air, a flower on stone, a
rail on a fence: each is a block a structure or a setblock writes and the
server drops the first time a shape update reaches it, because its
canSurvive rule asks a neighbour for something the neighbour does not give.
This module answers that rule for every blockstate of the pin, read from two
tables measured inside the pinned server jar by
tools/maintenance/dump-support.py (provenance in
crates/delvec/data/PROVENANCE.md):
crates/dsl/data/support-1.21.11.tsv— per state,free(it survives in air),support(the neighbours any one of which keeps it, each a base set the game names plus its exact differences), orunjudged(the single-neighbour reading cannot be its whole rule, with the reason);crates/dsl/data/support-bases-1.21.11.tsv— per state, the base sets’ own questions: CENTER- and RIGID-sturdy faces, air, solid, still water. The FULL-sturdy faces arecrate::blockshape::face_is_sturdy’s table.
Nothing here is classified by hand: a block is “attached” because the jar
says it does not survive in air, and what holds it is the set of neighbours
the jar said yes to. The compiler’s DW1002 judges every block of the world
a build writes with Needs::kept.
Structs§
- Rule
- One neighbour that keeps a block: the neighbour across
cellis inbase, or is one ofadded, and is not one ofremoved.
Enums§
Functions§
- needs
- What a block state needs beside it to survive, by the pinned jar, or
Nonefor a block the table does not hold (a non-minecraft:id, or one the pin lacks).