Skip to content

History / Logic Reference

Revisions

  • Kotlin is a slightly nicer formatter

    @cswendrowski cswendrowski committed Jun 6, 2026
  • Document ternary and zoom

    @cswendrowski cswendrowski committed Jun 6, 2026
  • Document manual crit/fumble marking + add roll features to Home - Logic-Reference: manual marking section (roll.crit = true), note crit/fumble are read/write and don't require a param when set manually; mention the rare crit-fumble state. - Home: add Crit & Fumble Flags and Dice Pool Inspection to game mechanics. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>

    @cswendrowski cswendrowski committed Jun 2, 2026
  • Crit highlight is green (was gold) Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>

    @cswendrowski cswendrowski committed Jun 2, 2026
  • Document roll crit/fumble flags and dice inspection (#10, #80) Logic-Reference: detection params (crit/fumble/success/failure) and the result accessors (crit, fumble, successes, highest, lowest, dice, count, contains). Recipes: update crit-hit recipe to natural-face crit:, add success-pool and EZD6-fizzle dice-pool recipes. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>

    @cswendrowski cswendrowski committed Jun 2, 2026
  • Document extension points

    @cswendrowski cswendrowski committed Jun 1, 2026
  • Document supported prompt input fields Prompts only accept one-shot input fields (string, number, boolean, the choice variants, parent/self references, die, dice, date/time/datetime). List them and note that persistent/display widgets, collections, and layouts are rejected with a validation error. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>

    @cswendrowski cswendrowski committed May 31, 2026
  • docs: parent.* requires an 'if (parent is X)' type guard The Basic-Logic parent example used parent.Mana / parent.XP without the required type check, which fails with 'Could not resolve reference to Property' (an Item can be owned by any Actor type, so parent must be narrowed before its fields resolve). Verified the guarded form generates cleanly. Updated the Basic-Logic example + added a note to the Logic-Reference parent syntax. (Recipes already used the guard correctly.)

    @cswendrowski cswendrowski committed May 30, 2026
  • Add new logic comparisons

    @cswendrowski cswendrowski committed May 26, 2026
  • docs: correct stale features after grammar / codegen verification After confirming behaviour against the codegen, several wiki claims were either half-implemented or never wired up. These changes bring the docs in line with what the generator actually does today. Interactivity / Logic-Reference: action modifiers - 'quick action' has no codegen support beyond grammar parsing - the modifier is parsed but the generated sheet treats it identically to a plain action. Removed the dedicated 'Quick and Macro Actions' example, kept 'macro action' (which is wired up to the Foundry macro hotbar), and added a note that 'quick' / 'secondary' modifiers are grammar-only until further notice. Interactivity / Logic-Reference: hooks - Replaced the misleading 'on buffApplied(...)' / 'on levelUpEvent' examples - ISDL has no way to *fire* custom hooks, only listen. Replaced with a working 'on createActor(...)' example. - Added a 'Listening to Foundry Hooks' section explaining that any identifier maps to Hooks.on(<name>, ...) for any Foundry- or module- emitted hook, alongside ISDL's own helper hooks (combat*, round*, turn*, preApply*, applied*, death). - Health-event hook parameters corrected to match the codegen: every applied/preApply hook receives (amount, damageType, damageMetadata). Interactivity / Logic-Reference: document updates - Replaced 'update self' / 'update parent' with the canonical 'self.update()' and 'self.delete()'. The 'update Self' grammar form is half-implemented in codegen (broken syntax in generated JS) and shouldn't be in the docs. - Reframed the Update section to explain that ISDL queues assignments inside an action and flushes at end-of-body; self.update() is only needed for in-action read-after-write. Fields: wounds resource - Tightened the wounds tag's documentation: it currently affects only the visual presentation of the resource bar (blue/teal gradient, reversed direction). The damage applicator does NOT auto-route to a wounds resource - users wanting damage to fill a wounds pool need to wire that up themselves (or use a preApplyDamage hook). Fields: pinned field - Clarified the pinning UX: items get pinned via a Pin toggle that appears on every item row in the table/inventory display. The 'pinned' field on the actor only controls *where* the pinned-items list renders. Users do not need to wire up the Pin toggle. Fields: measuredTemplate - Noted that a measuredTemplate field's value is a configuration object, not a number/string. It renders as a friendly summary in chat blocks but won't resolve usefully in numeric or string expressions outside that context. Logic-Reference: @js{...} - Added a warning callout that @js{...} is an escape hatch with no stable contract - what variables are in scope depends on where in the generated code the block lands, and may change as codegen evolves. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>

    @cswendrowski cswendrowski committed Apr 27, 2026
  • docs: address grammar-vs-wiki audit findings Fixes broken examples and adds documentation for features that exist in the langium grammar but were absent or misrepresented in the wiki. Broken examples now corrected: - Action params (Fields.md, Document.md): the wiki claimed 'action Heal(hidden: ...)' / 'action LevelUp(disabled: ...)' / 'action LevelUp(when: ...)' worked as conditional shorthands. They do not - the grammar's ActionParam rule only accepts visibility, icon, color, and label. Replaced with the two valid forms: static visibility prefix and visibility: method block returning a Visibility.X value. - Status syntax (Keywords-and-Journals, Keywords-Quick-Reference): the wiki used 'status X when: ... img: ...' (no parens, wrong key 'img:' vs grammar's 'svg:', and 'death' as a trailing modifier). Per the StatusProperty rule, params live in (...) parens, the icon param is 'svg:', and 'death' is a *prefix* on the declaration. - Tracker style (Fields, Recipes): grammar accepts 'segmented' (singular). Wiki used 'segments' (plural), which would not parse. - Paperdoll size: (Fields): grammar takes a PX literal, not named sizes. Wiki claimed small/medium/large. New documentation for previously undocumented features: - 'wounds resource' - the inverse-color sibling of 'health resource', for damage-pool style tracking. - Document-level parameters - actor and item declarations accept icon:, svg:, background:, description:, creatable:, default:. - chat (template: "...") - custom Handlebars template override for chat cards. - parent<type> supported types - mirrored the 14-type list from self<type> with examples beyond just parent<attribute>. - attribute style: and roll: parameters - both appear in grammar but only roll: was glimpsed in the tutorial. - choices<string> multi-select field - distinct from singular choice<string>; supports max: and initial:. - damage(roll:, type:) function - now has a Logic-Reference entry alongside roll(). - Visibility prefix shorthand subsection - the nine prefix keywords (gmOnly, secret, hidden, etc.) and what each enables. - 'item.X' iteration alias inside where: clauses - the rule that lets filters reference each item under test. - 'pips' deprecation note pointing users to tracker(style: segmented). Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>

    @cswendrowski cswendrowski committed Apr 27, 2026
  • docs: bring Logic-Reference chat and comparison sections to parity - Chat: added the 'wide' line form, the source-order rendering note, and the explicit statement that flavor/tag/wide accept any expression (not just string literals). Replaced the older quoted-string-only examples with ones that use roll variables, ternary flavor, and a wide line - matching the formal grammar table in Basic-Logic. - Comparisons: reordered the operator table to put 'equals' / '!equals' first as the preferred forms, '==' / '!=' second as alternatives. Added a one-sentence preamble explaining the convention. - Assignments: kept both '+=' and '++' in the reference table (a reference page should show what's accepted), but added a note that the wiki examples prefer the readable forms. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>

    @cswendrowski cswendrowski committed Apr 27, 2026
  • Wiki update

    @cswendrowski cswendrowski committed Aug 10, 2025