mirror of
https://github.com/Pasta-Devs/Marinara-Engine.git
synced 2026-12-03 19:00:50 +07:00
[PR #6710] [MERGED] feat(game): contests in ruleset combat: grab, shove and break free as data #7295
Labels
No labels
android
bug
bugfix
ci
client
code freeze pause
container
dependencies
docs
documentation
duplicate
enhancement
feature
feature
feature
feature-creep
fixed-in-refactor
fixed-in-staging
good first issue
help wanted
in-pr
in-pr
needs-codeowner-decision
normal-scope
old-codebase
old-codebase
pull-request
qol
question
refactor
regression
revisit later
roadmap
scope-risk
scope-risk
server
server
shared
soup
upstream
windows
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
Pasta-Devs/Marinara-Engine#7295
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/Pasta-Devs/Marinara-Engine/pull/6710
Author: @kolacheee
Created: 9/26/2026
Status: ✅ Merged
Merged: 9/26/2026
Merged by: @kolacheee
Base:
staging← Head:feat/ruleset-combat-contests📝 Commits (2)
ca89052feat(game): contests in ruleset combat: grab, shove and break free as datae3e00c8test(game): swing the strike a grapple left in hand; contests stay a part of the plan📊 Changes
35 files changed (+1945 additions, -43 deletions)
View changed files
📝
CHANGELOG.md(+2 -0)📝
docs/development/game-rulesets-and-sheets-implementation.md(+34 -2)📝
docs/development/ruleset-5e-2014.example.json(+54 -1)📝
docs/examples/rulesets/ember-roads.json(+50 -0)📝
docs/extending/ruleset.schema.json(+329 -0)📝
docs/extending/writing-rulesets.md(+90 -9)📝
docs/game/combat.md(+3 -1)📝
e2e/game-combat-director.e2e.ts(+7 -0)📝
packages/client/src/lib/ruleset-combat-board.ts(+1 -1)📝
packages/client/src/lib/ruleset-combat-log.ts(+30 -0)📝
packages/client/src/lib/ruleset-combat-menu.ts(+13 -4)📝
packages/client/src/localization/locales/en.json(+6 -0)📝
packages/server/src/services/capability-packages/package-manager.service.ts(+23 -0)📝
packages/server/src/services/game/ruleset-combat-director.service.ts(+30 -0)📝
packages/shared/src/features/ruleset-combat/creatures.ts(+19 -0)📝
packages/shared/src/features/ruleset-combat/encounter.ts(+67 -0)📝
packages/shared/src/features/ruleset-combat/grid.ts(+45 -0)📝
packages/shared/src/features/ruleset-combat/hold.ts(+10 -3)📝
packages/shared/src/features/ruleset-combat/index.ts(+4 -0)📝
packages/shared/src/features/ruleset-combat/options.ts(+79 -2)...and 15 more files
📄 Description
Linked issue
Closes #6707
Why this change
A ruleset's fight can attack, cast, heal, walk, react and buy signature actions, but it could not wrestle. Grabbing somebody, shoving them over or away and breaking free are the same move in most systems: each side rolls, adds its own number, and the winner changes what holds the loser or where the loser stands. None of it could be said, so the 5e package's grapple and shove were narration only, and a system like Ember Roads had no way to pin a foe in a fight at all. The author guide listed "no grapple or shove movement" under Not yet. This is C5d of real ruleset combat (plan doc, § Real ruleset combat).
What changed
Capability API 1.43 (file keys:
checksandcontestsin the combat block, andcheckson a creature). None of it names one game's words.Checks.
combat.checksare the numbers a contest reads, each a value off the sheet, read once when the fight begins, the way a defense or a save is. A creature written in plain numbers gives its ownchecks; one with a sheet reads them off it, andchecksjoins the keys a sheet replaces, so it may not give both.Contests. Each entry in
combat.contestsnames:reach, andstrike(it may take the place of one strike when an action buys several);from: { holding };onWin: the conditions itappliesto the loser (with the winner as their source and an optionalrounds), the conditions itendson either side, and apush.reachandpushneedcombat.distance. Differs from the issue on purpose: the issue gave the attacker a single check; both sides take a list, because breaking free rolls the better of two.The fight.
contestevent carries both sides and the winner. It opens no window.The menu.
Log. "Juno tries Grab on Ash-hound: 12 (6 + 6) + 3 = 15 with Brawn against 2 (1 + 1) + 2 = 4 with Brawn, and wins.", a line for a push, and a line for a condition a contest ended. New strings are localized in
en.json.Install gate: the ruleset keys, and a creature's
checksinline or in a catalog file, each need 1.43. Published schema: the generator also says a win does at least one thing.Examples.
Docs:
docs/extending/writing-rulesets.md): a new Contests section; the combat key list, the creature keys and On screen updated; and Not yet updated, where the stale "no grapple or shove movement" is replaced by what is still not done (dragging, size limits, a contest opening a window, conditions changing one).docs/game/combat.md), the regenerated JSON Schema, the plan doc's C5d notes and the CHANGELOG.Validation
pnpm checkpasses locallyCONTRIBUTING.mdManual verification notes
Run by the agent on
ca89052cf(this branch's one commit on staging613721b22), all exit 0:pnpm check,pnpm localization:check,pnpm version:check,pnpm regression:node(401/401),pnpm ruleset:schema(no diff after regeneration),pnpm smoke:ui(7/7), andpnpm regression:ui e2e/game-combat-director.e2e.ts e2e/ruleset-wound-sheet.e2e.ts e2e/ruleset-live-states.e2e.ts --project=desktop-chromium --workers=1(9/9, including both ruleset fights). Mobile projects were not run locally. Local CodeRabbit, three completed passes: six findings, all fixed, the third pass clean. They were: reuse one dice distribution for both forecasts, settling a certain hit or miss before building it; a log example the Markdown would have turned into a list; refuse the same check twice on one side, and a breaking-free contest that applies the hold it breaks; and the player page still calling a push future work.New lane
scripts/regressions/game-ruleset-combat-contests.regression.tscovers:Thirty-six deliberate breaks were each caught. Two of them first slipped through, because their tests could pass for the wrong reason; both tests were tightened until they caught them.
scripts/regressions/ruleset-combat-director.regression.tsplays sixty seeded positioned Ember Roads fights with everybody under the Engine. Contests are taken, sometimes won and never refused, and a picker that never takes one is caught.e2e/game-combat-director.e2e.tschecks the Contests group, its "to win" forecast, and that Break free is absent while nothing holds on.Older lanes are adjusted:
Still to verify by hand (not done by the agent):
Docs and release impact
docs-i18nbranch updated to match, or a[docs-i18n]follow-up issue opened (see CONTRIBUTING.md § Translated documentation)Docs touched:
docs/extending/writing-rulesets.md(not carried bydocs-i18n)docs/game/combat.md(carried bydocs-i18n)docs/extending/ruleset.schema.jsondocs/examples/rulesets/ember-roads.jsondocs/development/ruleset-5e-2014.example.jsonanddocs/development/game-rulesets-and-sheets-implementation.md(internal)CHANGELOG.mdTranslations are batched into one
[docs-i18n]issue after the last ruleset slice, by the maintainer's standing decision, so no per-PR issue is opened here.UI evidence (if applicable)
None attached. The browser case saves the full-page screenshot of the ruleset fight with the Contests group on the menu. The manual steps above cover the rest.
Summary by CodeRabbit
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.