Commit graph

118 commits

Author SHA1 Message Date
dd0323c53f Sheets phase C: every field kind, details panel, canvas panning
- 25 palette items over 23 kinds: basics, trackers (bars, ticks, clocks,
  dots, step/usage dice, ladders), formulas and dice buttons (rule
  language with sheet @names), lists (rows, mini table, chips, point pool
  that may go negative, bonds), slots, conditions, spell slots, XP,
  currency, heading, divider, picture.
- Per-kind settings in the inspector; hover excerpts and an in-app
  details panel for list entries; live redraw of dependent boxes.
- Canvas: the page stays put after edits (boxes can go anywhere), a
  screen of room past the boxes, drag-to-pan and edge scrolling.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-29 16:28:04 -06:00
2661744b06 Sheets phase B: main menu, Sheets list, sheet editor
- Main menu (Spreads, Sheets, Settings, Quit) on the theme background,
  with recent spreads and sheets; logo or ☰ returns to it.
- Sheets: data model, store, templates, snapshot undo; New sheet dialog
  (blank or a template); editor with folder tabs, snap-grid canvas on the
  spread background, field palette, inspector, Play/Build, status strip.
- Field kinds: Number, Text box (BBCode, live {@name}), Heading.
- PaletteList shared by the card and field palettes; shared top bar brand.
- Keys go to the screen that shows; theme reloads keep the screen.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-29 15:53:56 -06:00
16b34c40f6 Card palette: left dock Cards | List, search, click or drag to add
- CardCatalog: one list of card kinds for the palette, right-click New card
  and new-card names; Dice table and Deck are their own items.
- LeftDock holds the palette and List view in the shared dock tab style.
- Play greys the palette under a Switch to Build notice (replaces the
  greyed + Card button); + Card menu removed; Card palette button in Build.
- Templates dropped from the palette land where they are let go.
- Phones: + opens the palette full screen.
- docs/SHEETS.md: the Sheets and unified editor plan.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-29 14:58:56 -06:00
7ea2bbf3a8 Speed: lazy format menus, one-call dashed threads, kept inspector sections, queued card rebuilds
Profiling showed the delays come from Godot's own calls, not GDScript:
- Right-click format menus are made on the first right-click, not for
  every text field at build time.
- Dashed reference threads draw all their dashes in one call.
- Inspector rebuilds keep the closed sections and only remake open ones.
- Card rows are styled before they join the card.
- A Play/Build switch rebuilds cards in view at once and the rest a few
  per frame (CardRefreshQueue); threads redraw only now and then meanwhile.

Adds tests/perf_actions.gd, a timing tool for everyday actions.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-25 16:20:31 -06:00
d41a6e40aa Tests: 15 s budget, shared Godot workers; a freed Main cancels its roll
tools/run_tests.sh stops every run at 15 s and lists what was not run.
Suites are nodes run by tests/run_suites.gd, several per Godot process;
TestBase no longer compiles the app (AppTestBase does). Audit: fewer
repeats and less setup; 51 suites in about 12 s (was 45 s).

Fix a crash when a roll was still animating as its Main was freed.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-25 16:19:30 -06:00
tachyonwolf
5c69acbba0 Fix dots and drops when zoomed: read control rects in world space; 10px drop reach on input dots
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-21 08:48:35 -06:00
1735ed09fd Card threads, Morgan's welcome, and typing/scroll/wheel papercuts
- Card threads: a port on each card's bottom edge. Plain runs after any
  result (once the result's own threads finish); Otherwise runs only when
  no thread of the result ran. Saved as card_threads (LOGIC.md 3g).
- Typing on long cards no longer rebuilds the inspector or the card per
  key (~175 ms -> ~7 ms). Timing tool: tests/perf_typing.gd.
- "+ Add result" scrolls to the new row and focuses it.
- Mouse wheel zooms; Shift+wheel pans sideways; scrolling lists keep it.
- "SPREAD" caption over the switcher; Morgan's first-run welcome.
- docs/MECHANICS.md: checklist of table mechanics for planning.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-16 10:41:13 -06:00
f2cd982e43 Spellcheck in Build: red underlines, suggestions, spread dictionary
Titles, result text and details (card, inspector, Lore Entries) get red
wavy lines under misspelled words; right-click gives suggestions, Add to
dictionary (saved with the spread) and Ignore (this session). Uses the
Godot-Hunspell add-on's SpellChecker when it is installed; off on Android
and when the add-on is missing. English (en_US) dictionary included.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-15 12:50:14 -06:00
cc7cd0f660 Lore Index: the Book is renamed and is a tab beside the inspector
UI words only: Book -> Lore Index, Page -> Lore Entry (code keeps book and
BookPage). In Build the Inspector and the Lore Index share the dock as two
tabs (SideTabs); selecting on the spread goes back to the Inspector. In
Play the Lore Index opens alone.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-15 12:46:05 -06:00
48b57e284c Play shows that Build mode exists
A greyed + Card in Play's top bar explains that cards are added in Build,
offers Switch to Build and pulses the Build switch. The ☰ menu shows New
card greyed with a tip. The toast's button can now run any action.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-15 12:42:29 -06:00
4a1b365985 Cards: thicker coloured header, Build move handle, green selection glow
New theme colours: Card header (themes without it get a shade between the
card face and Card shading) and Selected (default Morgan's eye glint). The
card the inspector shows glows too, so one selected card is easy to see.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-15 12:39:37 -06:00
1e944fa27d Inspector: one list with the card and every result, each collapsible
Selecting a card or result on the spread opens its section and closes the
rest; sections opened by hand stay open, and a click or focus inside one
makes it the section edits go to. Only open sections build their fields.
Result sections edit the weight or range and the position; the card
section picks Weights or Ranges and Auto-sort.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-15 12:35:27 -06:00
f335faa5c5 Ranged cards: edit by Weights or Ranges, whole-row drag, auto-sort
A ranged card now stores that it is ranged, so an empty card can switch
between Plain and Ranged. Cards made ranged are edited by weight (die faces
per result; ranges follow the row order); a gap becomes an empty result.
Ranges mode keeps typed ranges, rows drag with their range, and auto-sort
(on by default) keeps rows in roll order. Old cards load as Ranges.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-15 12:29:52 -06:00
91c19980f7 Skip animations setting; questions animate like pauses; pop-ups fade in
View > Skip animations makes every roll instant (Shift-click still does it
for one roll). A roll with a question now animates up to it and on after
the answer, instead of jumping to the end. Pause and question pop-ups fade
and grow in unless the roll skips animations.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-15 12:25:08 -06:00
07d96a68f8 Spread folders: pick from a list, nesting, keep empty folders, Recent
- Move to folder is a submenu of existing folders (+ No folder, New folder…);
  typed names match existing folders without regard to case.
- Folders nest ("Traveller/Worlds"); each folder has New spread here… and
  Rename folder….
- When the last spread leaves a folder, ask Keep / Remove it; kept empty
  folders have Remove folder.
- Recent spreads at the top of the switcher.
- List view's "folders" are called groups in the UI (+ Group).
- TestBase gets the shared _wipe helper.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-14 19:19:47 -06:00
2ed91e7acd Spreads can roll cards from other spreads: [[Spread::Card]]
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>
2026-11-14 14:45:01 -06:00
77d262e969 Thread inspector says where Roll it with … instead is when it's hidden
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-14 14:40:03 -06:00
de942d57ee Book: the page editor reloads after undo and redo
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-14 14:39:26 -06:00
a4688c1a4b Long cards opened with show all get a Show less button
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-14 14:36:54 -06:00
0ec50cc1fc Spread folders (Move to folder…, submenus), useful switcher tooltip, clearer export names
A spread can be listed under a folder (saved in its file, kept by copies);
the switcher shows each folder as a submenu. The switcher's tooltip now
gives the card count, folder and what it does. Export menu: "Table Tarot
JSON… (full copy)" and "Export as a diagram (cards and threads only)".

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-14 14:35:35 -06:00
bd077ebadc Formatting: right-click Format menu in text fields, more toolbar buttons, sparkle/shimmer/flash
Every text field's right-click menu gains Format: Bold, Italic, Underline,
Strike-through, Colour, Size and Effect (Godot's wave, tornado, shake,
rainbow, pulse, fade plus the app's own sparkle, shimmer and flash, drawn
by RichTextEffects in ui/text_effects). The details toolbar adds U, S and
Effect.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-14 14:32:46 -06:00
05508e1c05 Delete key deletes the selection, asking first (View ▾ → Ask before deleting)
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-14 14:28:59 -06:00
bc2936cf15 Sound slider in View ▾ and ☰; built-in themes hide Delete
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-14 14:26:39 -06:00
a7fb931bb4 Rerolls show in the roll animation; MainRollingShow split out
A result that came up but was rolled again (a thread's roll again, Only
if) now flickers with a floating "rolled again" before the kept result
lights. main_rolling.gd hit 412 lines, so showing a roll at once moved to
MainRollingShow (delegators kept).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-14 14:25:21 -06:00
983d2bd839 Cards can cost to roll; pauses animate up to themselves and pop up
- 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>
2026-11-14 14:23:07 -06:00
3f13bc181c Threads: No repeats (every roll of a repeated thread gives a different result)
With Let me choose, that's "roll three different ones and pick one".
The thread label says "no repeats"; saved in the file as "distinct".

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-14 14:11:22 -06:00
6a460d17eb Batch rolls join the Earlier list with one sound; longer history
Batches saved to the history file but never reached the tray's Earlier
list, and played no sound. Now each roll shows there as "Name (2 of 5)"
and the batch plays one roll sound. Earlier keeps 30 rolls (was 6) and
the saved history 200 (was 50).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-14 14:09:01 -06:00
22d3613364 Plain tables can have a modifier that moves the result up or down rows
The pick is made by weight, then moved by the modifier's value; the
first and last rows catch anything past them. Why this? names the move.
Switching between plain and ranged clears the modifier, since its
meaning changes.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-14 14:05:09 -06:00
8592c9c059 Results can have Only if; List view rolls show the result at once
A roll table's result can now have "Can come up only if" (the same
show_if options use): while it's false the result is rolled again, and
the card shows the condition on the row. Rolling from List view skips
the animation.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-14 14:02:29 -06:00
b96fc02c0b Group marks: a clear corner tab in every theme, fixed default colour, Any colour…
The mark recoloured each theme's corner art, which was thin and often
hard to see. Now it's a filled corner tab with a contrasting outline,
the same in every theme; collapsed groups show it too. Groups without a
colour are blue everywhere (was the theme's highlight gold). Colour menus
for cards, threads and groups end with a full colour picker.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-14 13:55:46 -06:00
83800c2f0e Frames: corner pieces redraw on resize; built-in theme pictures get mipmaps
Fixed-colour corner pieces (leaves, rivets, clips, triangles) were drawn
by a zero-size layer that never redrew, so after a card changed size they
stayed at its old corners. Built-in theme pictures had no mipmaps, so
Terminal's 1 px lines flickered when zoomed out.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-14 13:52:53 -06:00
c341790d1a Roll timing tool (tests/perf_roll.gd, outside the suite)
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-14 13:48:08 -06:00
9d550408d8 Roll again and combine can apply to chosen columns only
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-14 13:42:11 -06:00
3aeb98c2fd Add to list: lists made there are lists, the result's text is the item, Allow repeats
Making a new value from an Add to list row made a number, which the list
picker then hid and which couldn't hold words. Now it makes a list. The
item starts as the result's own text. List cards get Allow repeats (add
every time, in order); off keeps adding only new items.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-14 13:40:20 -06:00
9a0d97e924 Grouping over open groups nests them instead of emptying them
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-14 13:37:38 -06:00
edb49fce27 Ledger entries are saved on the card and editable on the spread
The entries were only saved values of the spread, so copies, exports and
imports lost them. Now a Ledger card lists its entries (name and starting
value) in the spread file; current values stay saved values. Build mode
edits them on the card too. Older spreads take in the entries made on the
card when they open.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-14 13:36:03 -06:00
0ed2ba553b JSON import keeps a group's colour
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-14 13:26:50 -06:00
61a548902f Theme tiers 1-2: theme folders, mascot recolour, background scene and tile, frame sets, picture threads, sounds; nine new built-in themes
- ThemeAssets loads a theme's files; FrameSet + GradientMap (3-stop) generalise the card frame;
  ThreadStrip draws threads from a picture; BoardBackdrop draws scene and tile; MascotArt
  recolours Morgan by role (logo SVG now uses the Keep File importer); SoundBoard plays
  roll / card turn / thread / click / ambient with View > Sound levels.
- Vaporwave, Synthwave, Cozy Autumn, Rustic, Woodsy, Sky Blue, Frutiger Aero, Gothic, Terminal:
  generated art (tools/theme_art), sounds (tools/theme_sounds), settings (tools/theme_defs).
- Ten OFL fonts; --theme=<id> flag; docs/THEMES.md format spec; test_theme_assets.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-11 15:05:40 -06:00
66c9df1f2d DESIGN.md: Perilous Void Stage II built; the new book-table features
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-11 09:17:28 -06:00
200edfd67e Book tables: columns as one phrase, roll twice and combine, results saved into lists, one-option picks answer themselves
- 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>
2026-11-11 09:06:55 -06:00
3cba805ec4 UI: the Collection card kind is now called Ledger
Code names and JSON keys stay "collection".

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-11 08:39:07 -06:00
16ad73adfb Group marks: member cards' top-right corner in the group's colour
Groups get an optional colour (Colour menu on the group); uncoloured
groups use the theme token GROUP. The group frame's border matches.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-11 08:36:13 -06:00
194f157140 Build mode: drag a result's handle to reorder a card's results
Ranged cards keep their ranges in place so the results move through
them. The router case arrows share the same move_entry.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-11 08:23:25 -06:00
2d247e34b4 Thread nodes under a card stacked above theirs are hidden
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-11 08:20:30 -06:00
4f0d2e2c4e Deck mode: a drawn result fades only once the animation reveals it
DeckReveal holds an animated roll's draws until each result lights; the
cards-left count waits too. Fast rolls and any newer roll drop the holds.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-11 08:19:34 -06:00
f731c6ffbf Theme fonts: 13 bundled families and text/title pickers in the theme editor
Standard (Inter, Source Sans 3, Lora, Rokkitt), easy to read (Atkinson
Hyperlegible, Lexend, Andika, OpenDyslexic) and themed title faces (Cinzel,
IM Fell English, Uncial Antiqua, Orbitron, Special Elite). All OFL except
Special Elite (Apache 2.0); licence files sit beside the fonts. FontCatalog
builds faces, synthesising missing bold/italic.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-11 08:16:42 -06:00
0e45ea7abc Value pickers list the values columns save
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-10 21:26:55 -06:00
03bc168756 UI for scales: make, show and edit ordered-step values
- Making one: Scale (ordered steps) in + Card, the inspector's Type switch
  and the settings dialog; steps one per line and a starting step dropdown
  (InspectorScale); new scales get Low, Medium, High.
- Showing one: the variable card shows the current step and the steps in a
  row with the current one marked; the Variables tab stores a typed step
  number or name as the step.
- Plain words: Builder ops step_up, step_down, toward, at_least, at_most
  (BuilderScales; step_up/down need the board), DescribeScales phrases,
  scale effect rows (EffectsScaleRow) and step dropdowns in conditions.
- Help: a Scales topic after Values and changes.
- Tests: test_ui_scales, plus builder and describe cases.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-10 21:25:55 -06:00
1377368428 UI for cards with columns: header and cells, inspector Columns section, help
- TableCardColumns: the column-name header, each row's cells after its text
  (Play: wrapping text; Build: a field per cell, edited inline), cards widen
  per column, and in "each" mode the cell each column landed on is lit
  (Main.lit_columns, from the rolled node's columns).
- InspectorColumns: Add columns, add/rename/move/remove (cells kept in step),
  one roll vs each column, Save as (value picker) and Only if (condition
  builder); the result inspector gets a field per extra column.
- Help: a Columns topic after Ranged tables and dice.
- tests/test_ui_columns.gd.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-10 21:25:03 -06:00
8bbc7002a0 Thread dice must roll dice: Dice.roll_problem shared by the field and the board check
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-10 21:19:36 -06:00