This manual is for creators who want to build on The Sundering Rite — to add new content, extend existing types, or adapt the system to another setting. If you are a player, close this book. The surprises inside are not for you.
File Types and Schemas
Every piece of content in this project lives inside a file type. A file type defines what a piece of data is — its name, its fields, and how it renders on screen. Characters, locations, factions, spells, monsters, and lore all have their own file types, each with a schema that describes the shape of the data.
A schema is a JSON object with properties — one per field. Each property has a type (string, number, boolean, object, array) and optionally a description explaining what it holds. Some fields are required; others are optional. The schema is the contract: any file of that type must match it.
Example: the Character type has fields like name, class, level, hp, stats, and notes. A character file fills those fields with data. The schema does not care what the data says — only that it is the right shape.
File Type Config
Each file type has a config at /file-types/<slug>.json containing:
- name — the display name (e.g. "Character").
- content_type — always "json" for structured types, or "md" for markdown notes.
- designation — an optional role tag (e.g. "location" marks a type as a world location).
- context_visibility — how much of this type the AI sees: "pinned" (always), "searchable" (on demand), "partial" (summary only), or "hidden" (never).
- schema — a reference to the full schema at
/file-types/<slug>/schema.json.
- layout — a reference to the rendered layout at
/file-types/<slug>/layout.json.
Creating a New File Type
To add a new content type (e.g. "Ship" or "Prophecy"):
- Decide what fields it needs. Write them as schema properties.
- Write the config to
/file-types/<slug>.json with name and schema.
- Optionally write a layout to
/file-types/<slug>/layout.json for how it renders.
- The system auto-creates a folder named after the plural form (e.g.
/Ships/).
The slug is the display name lowercased with spaces replaced by dashes: "Power System" becomes power-system.
Reference Fields
Some fields point at other files. A reference field has referencedFileTypeSlug — the type of file it points at. When you write data into a reference field, use the target file's slug (e.g. "gribble" for a character named Gribble). The system resolves slugs to file IDs automatically.
Example: a Location might have a controllingFaction field with referencedFileTypeSlug: "faction". Writing "the-black-hand" into that field creates a link to the Black Hand faction file.
Computed Fields
Some fields derive their value from other fields. A computed field has an expression — a formula that reads the file's own data (via $self) or loads a referenced file (via load()). Computed fields are read-only: you never write them directly. Change the source fields or the expression instead.
Example: a character's armorClass might be computed as 10 + floor(($self.dexterity - 10) / 2) + (load($self.armor)?.acBonus ?? 0).
Layouts
A layout defines how a file type renders on screen. It uses a JSON structure with root and elements — visual building blocks like text stacks, image rows, stat bars, and reference links. Layouts are optional: if you omit one, the system generates a default.
The World Ruleset
The default living world ruleset at /Systems/Default Living World Ruleset.world-ruleset.json defines the game's mechanical foundation:
- 9 attributes: Might, Agility, Endurance, Intellect, Awareness, Willpower, Presence, Technique, Power.
- 5 resources: Health (100), Energy (100), Guard (25), Stress (0-10), Resolve (3).
- Advancement: 10 levels, hybrid XP system.
- Resolution: Hybrid — narrative by default, D&D 5e rolls when stakes spike.
- Conditions: Injured, Exhausted, Unstable, Recovering, Transformed.
You can modify the ruleset to change the game's mechanical foundation, or create a new one for a different setting.