A result's text can name a card in another spread, as "[[Treasure::Loot]]".
It rolls there (its own threads and references resolve in that spread)
and its changes apply to this spread's values. The inspector has
"+ Roll a card from another spread…" to pick one. Links show as
"Treasure › Loot" chips; nodes from there are marked so this spread's
cards aren't lit for them.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
- Costs to roll on any card: its roll button greys out (with the reason)
when there isn't enough, and pressing it pays. A thread that reaches it
asks first (Pay / Don't pay), reusing the pause question.
- A pause now plays the roll so far (dice, lights, threads), then pops up
Continue / Stop here / Later (the tray strip stays). After Continue the
rest animates instead of showing at once. Shift-click still skips it.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
New helpers: BoardGroups (group nesting and membership), BoardFileIO
(migrate, atomic writes), RollNodes (result-node helpers), RollLive (live
values and starting values) and RollTableFactory (new cards). RollPipes now
holds the pipe and pause frames, RollChoice reads options_from, and
RollTableIO cleans inputs. The original files keep one-line delegators.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
- column_join: a card with columns reads as one phrase ("Ash Canyons"), which threads save
- TableEntry.repeat: a result that rolls its column again N times and combines them
- Saving a result into a declared list value adds an item (RollContext.save_result)
- A pick with only one available option picks it without asking
- Lint, why facts, inspector controls, tests, LOGIC.md
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
- Scales: var_type scale with steps; stored as step names, read as step
numbers in rules (a quoted step name beside a scale reads as its number);
+= / -= move steps and stop at the ends; toward().
- Columns: RollTable.columns / column_rolls (row or each), TableEntry.cells;
RollColumns fills the other columns, saves each, honours a column's when.
- Threads: dice (roll with other dice instead) and reroll (result ids).
- RollTable save/load split into RollTableIO; Expr's base into ExprBase.
- RollLintBook checks; JSON canon keeps the new keys; tests.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
A thread with 'Wait for me first' (TableEntry.pipe_pause, JSON "pause")
stops the roll before it runs (Roller.OP_PAUSE, a "pause" request). The
tray shows Continue ▸ and Stop here; starting another roll sets the paused
one aside with its chip kept, and Continue makes it the current roll again
(RollPauses; each roll's token lives in a holder so it can be revived).
Stop here ends the roll and the chip says where it stopped. Headless rolls
continue.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
A thread that rolls its card more than once gets a 'then' choice
(TableEntry.pipe_combine, JSON "combine"): keep every roll (as before),
add them together, keep the highest or lowest, or let the player choose
(the choice pop-up). The repeats hold their own threads until the combine
step (Roller.OP_COMBINE, RollCombine) keeps one, which then follows its
threads; save-as keeps the total or the kept result. Set-aside rolls show
faded in the tray.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The execution loop, node helpers and live display stay in Roller; every
Roller function and constant used elsewhere keeps a one-line delegator.
No behaviour change.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
- Cards read the inspector's selection ({kind, tid, eid}) and the
inspector marks the selected row on every card when it changes.
- A variable card's starting value now applies: before a top-level
roll, each declared variable that isn't set yet and has a starting
value is set to it (a "starts at 9" Strength no longer reads as 0).
- Check cards in Build no longer repeat "Success Success": a result
text equal to the outlet name shows as an empty field with a hint.
- test_options switches to the Text view through Main.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Implements docs/PLAIN.md sections 1-5 (the engine half of the usability pass):
- core/describe.gd (Describe): rules in plain words, labelled from variable
cards, collections and card inputs, falling back to the original text.
- core/builder.gd (Builder): effect and condition models that round-trip
with the rule text, a rule tokenizer, and known_values(board).
- Collections: variable cards with var_type "collection" label their
members and don't declare their stem.
- Check cards (kind "check"): dice + modifier vs target, Success/Failure,
chain values nat/total/effect, node "check" info, lint and static checks.
- Card inputs and pipe "with" values, scoped over the pipe's subtree on the
explicit work stack (OP_RESTORE frames), with defaults and snapshot
evaluation.
- nat on every roll-table roll; dice faces recorded through ctx.faces.
- Why trace: facts on nodes and steps (input, roll, check, case, show_if,
options_where, effect, when, otherwise).
- StateStore rules_view setting; JSON for the new keys; LOGIC.md and
PLAIN.md updated (deviations in PLAIN.md 5a).
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Pick choice cards can take their options from variables (options_from:
@prefix_* or a @list, filtered by options_where with option, option_label
and option_value bound). A Chosen entry runs for whichever dynamic option
is picked; fixed entries stay as extras, listed first. Random weighs each
dynamic option as the Chosen entry and fixed ones by weight. Any pick
option can have show_if, which hides it from the pop-up and from Random;
with nothing offered the node stops with "No options available".
@[expr] reads or writes the variable named by expr in expressions,
effects (including reset) and text ({@[expr]}); bad computed names are
effect errors. JSON round trip, lint_options in lint_pipes, choice
pop-up value badges and previews, card and settings UI, docs, demo board
(Spend a find) and tests/test_options.gd.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Pipes can carry "when" (Only if) and "otherwise". When an entry is
chosen, its effects run, its text expands, then every pipe condition and
count is evaluated once as a snapshot before any pipe runs; when pipes
run if true, otherwise pipes if no when pipe was true, plain pipes
always. Condition errors count as false and show as error lines.
New router card (kind "router"): its entries are cases with an
entry-level "when"; the first true case is chosen (empty = Otherwise),
and "No case matched" stops the node. One action. JSON round trip for
entry/pipe when and pipe otherwise, including JsonIO.canonical and
edge labels. Roller.lint_pipes() and Roller.lint_router() for board
checks. A pick choice's save_as is now stored before the snapshot.
UI: Only if / Otherwise in the pipe popover with live validation, pipe
labels ("if @str >= 8", "otherwise") and a source-end diamond on
conditional pipes, router card with fork icon, per-case condition rows,
case editing / reordering in Build, router settings, "+ Table" entry,
router cases in table previews. Logic demo now routes through a router.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
- Expr: @vars, chain vars, dice tokens, dm/has/count, lone = as ==, errors as values, parse cache
- Effects: = += -= *= /= and reset (with prefix), number vs list semantics, logs, validation
- RollTable kinds and per-kind fields with factories; expression dice with end clamping
- TableEntry effects and expression pipe counts; JSON round trip through JsonIO
- TextExpander: {@prefix_*}, {= expr}, number display, expand_async and live render()
- Roller: coroutine with an explicit work stack, prompts for choice cards, loops,
10,000-action limit, partial tree on ctx.root, iterative flatten/collect_lit
- Variables keep numbers as numbers through StateStore
- Main: awaits the roll with a default (headless) prompt hook, iterative playback,
long chains show at once
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Entry text is expanded by TextExpander with a shared RollContext; inline
reference rolls become children marked inline, pipes with save_as save the
child's export BBCode. MAX_DEPTH is 32. Steps carry BBCode text, depth and
inline/reshuffle flags. Adds tests/test_integration.gd.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Tables are cards on a felt board, joined by copper pipes that carry a
roll from one table to the next. Play mode rolls with a flicker and a
bead down each pipe; Build mode edits names, results, ranges and pipes.
- core/: data model (RollTable, TableEntry, TowerBoard), sample board
with a d100 table of 100 trinkets and a weighted d100 range table,
and a Roller with a depth limit
- ui/: board with pan and zoom, pipe and port layers, collapsible table
cards, result tray with earlier rolls, undo toasts, and a Collapse all
/ Expand all button
- assets/fonts/: Rokkitt and Atkinson Hyperlegible (SIL OFL)
- tests/test_roller.gd: headless checks for the model and roller
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>