[PR #7589] [MERGED] Rulesets: Game Master combat rules for 5e fights, part 3, and the GM intro message #7816

Closed
opened 2026-10-24 04:07:46 +07:00 by bsakaguchi · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/Pasta-Devs/Marinara-Engine/pull/7589
Author: @kolacheee
Created: 10/14/2026
Status: ✅ Merged
Merged: 10/14/2026
Merged by: @kolacheee

Base: staging ← Head: feat/ruleset-gm-rules-4


📝 Commits (10+)

  • 543b0fa Ruleset combat: light and fog drawn on the fight board
  • d8994b9 Ruleset combat: lair actions (Capability API 1.310)
  • 27d217e Ruleset combat: breakable props that tell the story (Capability API 1.311)
  • b721081 Ruleset combat: Legendary Resistance, and scrolls held to a size (Capability API 1.312)
  • 9a41cd5 Ruleset combat: gate an item use's targetsUpTo at 1.312 again
  • a03be38 Ruleset combat: board events and growth (Capability API 1.313)
  • 832d136 Ruleset combat: shade, light rules, chimes and the light-shy (Capability API 1.314)
  • 1ad2fa3 Ruleset combat: the 1.313 and 1.314 log samples keyed by event, and the schema file
  • 8dea5da Ruleset combat: an item effect that only alerts is read (1.314 fix)
  • 3621a3e Ruleset combat: growing auras, holds with a most, tearing free and hanging on (Capability API 1.315)

📊 Changes

103 files changed (+19037 additions, -1104 deletions)

View changed files

📝 docs/extending/ruleset.schema.json (+4543 -670)
📝 docs/extending/writing-rulesets.md (+58 -0)
📝 docs/extending/writing-story-scripts.md (+51 -23)
➕ packages/client/src/components/game/ArtIcon.tsx (+36 -0)
📝 packages/client/src/components/game/GameCombatUI.tsx (+12 -1)
📝 packages/client/src/components/game/GameInventory.tsx (+29 -3)
📝 packages/client/src/components/game/GameNarration.tsx (+29 -11)
📝 packages/client/src/components/game/GamePartyBar.tsx (+20 -6)
📝 packages/client/src/components/game/GameRulesetSheet.tsx (+6 -0)
➕ packages/client/src/components/game/GameSetupGmIntro.tsx (+105 -0)
📝 packages/client/src/components/game/GameSetupWizard.tsx (+41 -20)
📝 packages/client/src/components/game/GameSurface.tsx (+1 -0)
📝 packages/client/src/components/game/RulesetCombatBoard.tsx (+157 -25)
📝 packages/client/src/components/game/RulesetCombatMenu.tsx (+5 -1)
📝 packages/client/src/components/game/RulesetCombatStatus.tsx (+18 -1)
📝 packages/client/src/components/game/RulesetItemPicker.tsx (+11 -0)
📝 packages/client/src/components/game/TacticalCombatUI.tsx (+51 -15)
➕ packages/client/src/lib/art-pack.ts (+56 -0)
➕ packages/client/src/lib/board-art-cells.ts (+134 -0)
➕ packages/client/src/lib/board-art.ts (+35 -0)

...and 80 more files

📄 Description

Linked issue

Part of #7469

This follows #7588 (merged), the second part of the Game Master's ruleset combat rules. This branch is up to date with staging and holds the third part, with the Game Master's intro message: Capability API 1.315-1.339, so the supported version is 1.339. Maps and the remaining work follow this one at a time.

Why this change

  • 5e's lairs, legendary creatures and bosses still lacked lair actions, Legendary Resistance, growing or lingering auras, and creatures that call others in or draw people toward them.
  • A fight's board could not change as rounds pass: nothing stood on it to break, nothing grew, and it was always drawn in plain colours.
  • A rest could not spend 5e's Hit Dice, and a game had no way to open with the Game Master's own intro message.

What changed

  • Lairs and legendary creatures: lair actions taken on the lair's count (Capability API 1.315), Legendary Resistance (1.317), and lair timing: a creature action only at whoever has acted this round, a broken concentration that picks the next lair action, and a condition lasting until the next lair action (1.327). A broken concentration can pick from a list of lair actions (1.336).
  • Bosses: an aura that grows, lingers or harms on its targets' turns, a hold with a most, tearing free, and a creature that hangs on at 1 (1.320). Creature actions can leave an area standing or change the ground (1.324), call creatures into the fight (1.325), and draw whoever they land on toward them (1.326). A condition can move the difficulty of the saves its holder calls for (1.328).
  • The board: props that can be broken, and attacks pointed at them (1.316). Board events and growth, and entries or item uses that clear growth (1.318). Board events can carry whoever stands on the ground toward an edge (1.329). Props can be lit again, uses can need to be beside a prop, and a change to the ground can leave whoever stands there in it (1.332). Conditions can hold only near a prop, areas can stand around props, and an aura can feed on the felled (1.331).
  • Light: lights that shed shade, chimes that give the unseen away, and creatures held still by light (1.319). A board's light rule can be saved against, and says how far it moves a track at most (1.321). Nobody lights a torch in daylight.
  • Held Ground: a fight on ground where death is held, with blows that reap (1.323), and Held Ground let go in the middle of a fight, with its marks coming due (1.330).
  • Items: an item's use can be aimed only at creatures up to a size (1.317), be taken as a reaction (1.322), and give its user more of the turn (1.334).
  • Rests: a rest can spend dice to heal, as 5e's Hit Dice (1.335), from several pools (1.337).
  • Art: a fight's board can be drawn from a board pack, and a lasting area with its own art (1.333). Catalog entries and conditions can name their icon, and portraits come from packs of their own kind (1.338). Board packs get their own table, storage and routes, and the launcher's data protection includes them.
  • The Game Master's intro message (1.339): the GM setup and a story's intro can set the game's first message exactly, or guide the one the Game Master writes, and a story can lock it. A defined intro is never rewritten by an agent or after a roll.
  • docs/extending/writing-rulesets.md and docs/extending/writing-story-scripts.md cover all of it, and docs/extending/ruleset.schema.json is regenerated.

Validation

  • pnpm check passes locally
  • Container (Docker / Podman) built and ran without issue
  • Ran the app, clicked through the changes manually
  • Checked edge cases (light + dark mode, mobile viewport, empty states, error paths)
  • Above manual verification completed (describe below)
  • Read and followed CONTRIBUTING.md
  • Regression lanes run locally on this head: capability 19/19, package 7/7, creature 10/10, game-ruleset 222/222, inventory 4/4, avatar 14/14, board 7/7, tile 1/1, world-map-packs, game-intro-message, ruleset-rest-dice, art-icons, game-dice and generate all pass; native-export-memory passes 3 of 3.

Manual verification notes

  • Each feature has its own regression under scripts/regressions/game-ruleset-combat-*.regression.ts that drives a fight through the shared resolver, and checks the install gate at its version.
  • The install scans added here skip a ruleset's own id-keyed maps, as #7588's do: game-ruleset-combat-lair checks that a row whose values are named lair, icon, clears or the like asks for nothing newer.
  • Not checked by a person yet: these rules in a live game with a full 5e ruleset.

Changed test expectations

No maintainer asked for these; each follows a change in this PR, and the check it replaces is kept:

  • Supported Capability API 1.314 to 1.339, and the unsupported fixture 1.315 to 1.340 (capability-package-lifecycle): this PR's versions run to 1.339.
  • An aura with nothing to do is still refused; the message now names feeding as well (game-ruleset-combat-aura-turns, 1.331).
  • game-ruleset-combat-darkness's "who sheds light" case now runs on a dark board, since nobody lights a torch in daylight (1.319). game-ruleset-combat-light-switch checks the daylight case itself.
  • game-ruleset-combat-relight-ice's "by its id" case now runs a whole fight against a prop under another label, instead of reusing the label case's fight; the check is the same.
  • The new regressions' supportedCapabilityApi.minor floors now match each file's own version (each went up).
  • game-ruleset-combat-item-reactions now also checks the reaction's outcome is not a miss.
  • ruleset-combat-screen-client expects the plainer Held Ground death line ("Thorn Lurker died.").

Docs and release impact

  • No docs changes needed
  • Updated docs (README / CONTRIBUTING / android/README) as needed
  • Translated docs on the docs-i18n branch updated to match, or a [docs-i18n] follow-up issue opened (see CONTRIBUTING.md § Translated documentation)
  • Version/release files updated (only if this PR includes a version bump)
  • docs/extending/writing-rulesets.md and docs/extending/writing-story-scripts.md changed, and docs/extending/ruleset.schema.json is regenerated. The translations are tracked on #7512.

UI evidence (if applicable)

No screenshots attached. The combat board, menu, status, log, icons and setup changes are covered by the regressions above.

Summary by CodeRabbit

  • New Features
    • Added custom board artwork, portraits, and icons across combat, inventory, party, dialogue, conditions, and action menus, with fallbacks when artwork is unavailable.
    • Added configurable Game Master opening messages, with guided, defined, and no-intro options.
    • Expanded combat with lair actions, destructible props, scheduled battlefield changes, lighting and growth effects, creature calls, Held Ground, and other advanced rules.
    • Added rest-dice healing, including multiple dice pools and eligible item bonuses.
    • Added support for saving, importing, and selecting custom board and art packs.
    • Added combat log and recap details for new battlefield and combat events, plus story triggers for broken battlefield props.
  • Documentation
    • Expanded ruleset and story-script guides with new combat, battlefield, and intro options.

🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/Pasta-Devs/Marinara-Engine/pull/7589 **Author:** [@kolacheee](https://github.com/kolacheee) **Created:** 10/14/2026 **Status:** ✅ Merged **Merged:** 10/14/2026 **Merged by:** [@kolacheee](https://github.com/kolacheee) **Base:** `staging` ← **Head:** `feat/ruleset-gm-rules-4` --- ### 📝 Commits (10+) - [`543b0fa`](https://github.com/Pasta-Devs/Marinara-Engine/commit/543b0fa1444c56b8598e0b06d40942b94c200383) Ruleset combat: light and fog drawn on the fight board - [`d8994b9`](https://github.com/Pasta-Devs/Marinara-Engine/commit/d8994b9c3a2758efcf25eba0c6cf4161f1dd2b06) Ruleset combat: lair actions (Capability API 1.310) - [`27d217e`](https://github.com/Pasta-Devs/Marinara-Engine/commit/27d217e618c38b51a14f050248c8e712b04b949d) Ruleset combat: breakable props that tell the story (Capability API 1.311) - [`b721081`](https://github.com/Pasta-Devs/Marinara-Engine/commit/b7210811ace2957968828f3430ca041a4adeae02) Ruleset combat: Legendary Resistance, and scrolls held to a size (Capability API 1.312) - [`9a41cd5`](https://github.com/Pasta-Devs/Marinara-Engine/commit/9a41cd50d8078accb7329ba2c3c86e6559536c1b) Ruleset combat: gate an item use's targetsUpTo at 1.312 again - [`a03be38`](https://github.com/Pasta-Devs/Marinara-Engine/commit/a03be38f9df04d1dce78f279b5add8a920ad7336) Ruleset combat: board events and growth (Capability API 1.313) - [`832d136`](https://github.com/Pasta-Devs/Marinara-Engine/commit/832d13623e7afc0e037586352e5a440a027fc604) Ruleset combat: shade, light rules, chimes and the light-shy (Capability API 1.314) - [`1ad2fa3`](https://github.com/Pasta-Devs/Marinara-Engine/commit/1ad2fa35c68c342be784fa37bc4cfb96c9ad8ce5) Ruleset combat: the 1.313 and 1.314 log samples keyed by event, and the schema file - [`8dea5da`](https://github.com/Pasta-Devs/Marinara-Engine/commit/8dea5da4860b211f1797bd2a27723b6eafbd03dc) Ruleset combat: an item effect that only alerts is read (1.314 fix) - [`3621a3e`](https://github.com/Pasta-Devs/Marinara-Engine/commit/3621a3eebecba2652093b85b3710513c5701896c) Ruleset combat: growing auras, holds with a most, tearing free and hanging on (Capability API 1.315) ### 📊 Changes **103 files changed** (+19037 additions, -1104 deletions) <details> <summary>View changed files</summary> 📝 `docs/extending/ruleset.schema.json` (+4543 -670) 📝 `docs/extending/writing-rulesets.md` (+58 -0) 📝 `docs/extending/writing-story-scripts.md` (+51 -23) ➕ `packages/client/src/components/game/ArtIcon.tsx` (+36 -0) 📝 `packages/client/src/components/game/GameCombatUI.tsx` (+12 -1) 📝 `packages/client/src/components/game/GameInventory.tsx` (+29 -3) 📝 `packages/client/src/components/game/GameNarration.tsx` (+29 -11) 📝 `packages/client/src/components/game/GamePartyBar.tsx` (+20 -6) 📝 `packages/client/src/components/game/GameRulesetSheet.tsx` (+6 -0) ➕ `packages/client/src/components/game/GameSetupGmIntro.tsx` (+105 -0) 📝 `packages/client/src/components/game/GameSetupWizard.tsx` (+41 -20) 📝 `packages/client/src/components/game/GameSurface.tsx` (+1 -0) 📝 `packages/client/src/components/game/RulesetCombatBoard.tsx` (+157 -25) 📝 `packages/client/src/components/game/RulesetCombatMenu.tsx` (+5 -1) 📝 `packages/client/src/components/game/RulesetCombatStatus.tsx` (+18 -1) 📝 `packages/client/src/components/game/RulesetItemPicker.tsx` (+11 -0) 📝 `packages/client/src/components/game/TacticalCombatUI.tsx` (+51 -15) ➕ `packages/client/src/lib/art-pack.ts` (+56 -0) ➕ `packages/client/src/lib/board-art-cells.ts` (+134 -0) ➕ `packages/client/src/lib/board-art.ts` (+35 -0) _...and 80 more files_ </details> ### 📄 Description ## Linked issue Part of #7469 This follows #7588 (merged), the second part of the Game Master's ruleset combat rules. This branch is up to date with staging and holds the third part, with the Game Master's intro message: Capability API 1.315-1.339, so the supported version is 1.339. Maps and the remaining work follow this one at a time. ## Why this change - 5e's lairs, legendary creatures and bosses still lacked lair actions, Legendary Resistance, growing or lingering auras, and creatures that call others in or draw people toward them. - A fight's board could not change as rounds pass: nothing stood on it to break, nothing grew, and it was always drawn in plain colours. - A rest could not spend 5e's Hit Dice, and a game had no way to open with the Game Master's own intro message. ## What changed - **Lairs and legendary creatures:** lair actions taken on the lair's count (Capability API 1.315), Legendary Resistance (1.317), and lair timing: a creature action only at whoever has acted this round, a broken concentration that picks the next lair action, and a condition lasting until the next lair action (1.327). A broken concentration can pick from a list of lair actions (1.336). - **Bosses:** an aura that grows, lingers or harms on its targets' turns, a hold with a most, tearing free, and a creature that hangs on at 1 (1.320). Creature actions can leave an area standing or change the ground (1.324), call creatures into the fight (1.325), and draw whoever they land on toward them (1.326). A condition can move the difficulty of the saves its holder calls for (1.328). - **The board:** props that can be broken, and attacks pointed at them (1.316). Board events and growth, and entries or item uses that clear growth (1.318). Board events can carry whoever stands on the ground toward an edge (1.329). Props can be lit again, uses can need to be beside a prop, and a change to the ground can leave whoever stands there in it (1.332). Conditions can hold only near a prop, areas can stand around props, and an aura can feed on the felled (1.331). - **Light:** lights that shed shade, chimes that give the unseen away, and creatures held still by light (1.319). A board's light rule can be saved against, and says how far it moves a track at most (1.321). Nobody lights a torch in daylight. - **Held Ground:** a fight on ground where death is held, with blows that reap (1.323), and Held Ground let go in the middle of a fight, with its marks coming due (1.330). - **Items:** an item's use can be aimed only at creatures up to a size (1.317), be taken as a reaction (1.322), and give its user more of the turn (1.334). - **Rests:** a rest can spend dice to heal, as 5e's Hit Dice (1.335), from several pools (1.337). - **Art:** a fight's board can be drawn from a board pack, and a lasting area with its own art (1.333). Catalog entries and conditions can name their icon, and portraits come from packs of their own kind (1.338). Board packs get their own table, storage and routes, and the launcher's data protection includes them. - **The Game Master's intro message (1.339):** the GM setup and a story's `intro` can set the game's first message exactly, or guide the one the Game Master writes, and a story can lock it. A defined intro is never rewritten by an agent or after a roll. - `docs/extending/writing-rulesets.md` and `docs/extending/writing-story-scripts.md` cover all of it, and `docs/extending/ruleset.schema.json` is regenerated. ## Validation - [x] `pnpm check` passes locally - [ ] Container (Docker / Podman) built and ran without issue - [ ] Ran the app, clicked through the changes manually - [ ] Checked edge cases (light + dark mode, mobile viewport, empty states, error paths) - [ ] Above manual verification completed (describe below) - [ ] Read and followed `CONTRIBUTING.md` - Regression lanes run locally on this head: capability 19/19, package 7/7, creature 10/10, game-ruleset 222/222, inventory 4/4, avatar 14/14, board 7/7, tile 1/1, world-map-packs, game-intro-message, ruleset-rest-dice, art-icons, game-dice and generate all pass; native-export-memory passes 3 of 3. ### Manual verification notes - Each feature has its own regression under `scripts/regressions/game-ruleset-combat-*.regression.ts` that drives a fight through the shared resolver, and checks the install gate at its version. - The install scans added here skip a ruleset's own id-keyed maps, as #7588's do: `game-ruleset-combat-lair` checks that a row whose values are named `lair`, `icon`, `clears` or the like asks for nothing newer. - Not checked by a person yet: these rules in a live game with a full 5e ruleset. ### Changed test expectations No maintainer asked for these; each follows a change in this PR, and the check it replaces is kept: - Supported Capability API 1.314 to 1.339, and the unsupported fixture 1.315 to 1.340 (`capability-package-lifecycle`): this PR's versions run to 1.339. - An aura with nothing to do is still refused; the message now names feeding as well (`game-ruleset-combat-aura-turns`, 1.331). - `game-ruleset-combat-darkness`'s "who sheds light" case now runs on a dark board, since nobody lights a torch in daylight (1.319). `game-ruleset-combat-light-switch` checks the daylight case itself. - `game-ruleset-combat-relight-ice`'s "by its id" case now runs a whole fight against a prop under another label, instead of reusing the label case's fight; the check is the same. - The new regressions' `supportedCapabilityApi.minor` floors now match each file's own version (each went up). - `game-ruleset-combat-item-reactions` now also checks the reaction's outcome is not a miss. - `ruleset-combat-screen-client` expects the plainer Held Ground death line ("Thorn Lurker died."). ## Docs and release impact - [ ] No docs changes needed - [x] Updated docs (README / CONTRIBUTING / android/README) as needed - [x] Translated docs on the `docs-i18n` branch updated to match, or a `[docs-i18n]` follow-up issue opened (see CONTRIBUTING.md § Translated documentation) - [ ] Version/release files updated (only if this PR includes a version bump) - `docs/extending/writing-rulesets.md` and `docs/extending/writing-story-scripts.md` changed, and `docs/extending/ruleset.schema.json` is regenerated. The translations are tracked on #7512. ## UI evidence (if applicable) No screenshots attached. The combat board, menu, status, log, icons and setup changes are covered by the regressions above. <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit * **New Features** * Added custom board artwork, portraits, and icons across combat, inventory, party, dialogue, conditions, and action menus, with fallbacks when artwork is unavailable. * Added configurable Game Master opening messages, with guided, defined, and no-intro options. * Expanded combat with lair actions, destructible props, scheduled battlefield changes, lighting and growth effects, creature calls, Held Ground, and other advanced rules. * Added rest-dice healing, including multiple dice pools and eligible item bonuses. * Added support for saving, importing, and selecting custom board and art packs. * Added combat log and recap details for new battlefield and combat events, plus story triggers for broken battlefield props. * **Documentation** * Expanded ruleset and story-script guides with new combat, battlefield, and intro options. <!-- end of auto-generated comment: release notes by coderabbit.ai --> --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
bsakaguchi 2026-10-24 04:07:46 +07:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
Pasta-Devs/Marinara-Engine#7816
No description provided.