Skip to content

fix(game): clarify hero names and opportunity attack lines (#1822) - #1824

Merged
Garblesnarff merged 4 commits into
mainfrom
fix/1822-hero-and-reaction-copy
Nov 30, 2026
Merged

Garblesnarff merged 4 commits into
mainfrom
fix/1822-hero-and-reaction-copy

Conversation

@Garblesnarff

@Garblesnarff Garblesnarff commented Nov 30, 2026 •

Copy link
Copy Markdown
Owner

Refs #1822 (items 1 and 2)

The hero card shows the typed name alone for a personal-name premade and keeps a title starting with The as an epithet. Card tests cover both the heading and Playing as text.

The shared attack formatter names the weapon without a pronoun in both ordinary attack lines and opportunity reactions. Reaction text retains the existing automatic-roll disclosure, damage details and outcome. Unit coverage checks the hit and miss forms. Three real-DB suites passed, including the updated assertions from #1788 after it landed.

Friction / simplification

The same formatter now writes the reaction line and the pending DM fact. I merged current main before updating the tests that #1788 had owned and ran direct lint and diff checks.

Head SHA 7528ce6b78b11301e9350a8f4f40ab1c335c2529

@coderabbitai

coderabbitai Bot commented Nov 30, 2026 •

Copy link
Copy Markdown

Important

  • Trigger review

This repository does not receive automatic reviews because it has fewer than 10 stars.

Run configuration

  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: defaults
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: ef5e9202-e87d-4fd9-915a-3729fe51a512
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

Share

Copy link
Copy Markdown
Owner Author

Strategist review — FIX at 6bb3c57

CI: pull_request run 46342948931, green.

  • Item 1 is correct: shared/hero-name.ts:31-34 shows the typed name alone unless the title starts with "The "; every caller falls back to the title when the typed name is empty; both cases are tested (14 + 47 tests pass in the reviewer's run).
  • Item 2: the wording is right, but it is built by a second function with its own rules.
  • The merge result with main is clean. No overlap with other open PRs.

Required:

  1. Remove describeOpportunityAttack (player-exit-service.ts:195-212). It copies describeResolvedAttack (attack-narration.ts) with different rules: it drops the (auto-rolled) disclosure and the damage-parts sentence. Keep one function: change the weapon phrase in describeResolvedAttack (attack-narration.ts:39, with its ${weaponName}) to with ${Weapon} (capital first letter, no pronoun), and use it again for the opportunity line with the Opportunity attack: prefix as on main. Decision: this applies to every attack line, not only opportunity attacks: "its" is wrong for a person in all of them. Update the tests that hold the old text (change the expected text; do not delete or loosen them).
  2. A unit test of the hit form and the miss form of the opportunity line outside the real-DB suite.

Push to the same branch. Post the head and the run id on #1822.


Generated by Claude Code

@Garblesnarff Garblesnarff left a comment

Copy link
Copy Markdown
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Strategist review — FIX at 6bb3c57

CI: pull_request run 46342948931, green.

  • Item 1 is correct: shared/hero-name.ts:31-34 shows the typed name alone unless the title starts with "The "; every caller falls back to the title when the typed name is empty; both cases are tested (14 + 47 tests pass in the reviewer's run).
  • Item 2: the wording is right, but it is built by a second function with its own rules.
  • The merge result with main is clean. No overlap with other open PRs.

Required:

  1. Remove describeOpportunityAttack (player-exit-service.ts:195-212). It copies describeResolvedAttack (attack-narration.ts) with different rules: it drops the (auto-rolled) disclosure and the damage-parts sentence. Keep one function: change the weapon phrase in describeResolvedAttack (attack-narration.ts:39, with its ${weaponName}) to with ${Weapon} (capital first letter, no pronoun), and use it again for the opportunity line with the Opportunity attack: prefix as on main. Decision: this applies to every attack line, not only opportunity attacks: "its" is wrong for a person in all of them. Update the tests that hold the old text (change the expected text; do not delete or loosen them).
  2. A unit test of the hit form and the miss form of the opportunity line outside the real-DB suite.

Push to the same branch. Post the head and the run id on #1822.


Generated by Claude Code

Copy link
Copy Markdown
Owner Author

Strategist review — PASS at 7528ce6

CI: pull_request run 46344822773, green.

  • The second function is gone. The opportunity line is one describeResolvedAttack call with the Opportunity attack: prefix (player-exit-service.ts:237, :252). The (auto-rolled) note and the damage-parts sentence stay.
  • attack-narration.ts:39: "with ", first letter capital only ("Unarmed Strike", "Longsword", "+1 Dagger" unchanged; an empty name gives no phrase). No "with its" is left in player text.
  • Hit and miss unit tests are outside the real-DB suite. Three real-DB tests now assert the exact text (tighter, not looser).
  • Hero name (item 1) is unchanged since round 1.
  • Reviewer runs: client 61, server 32 pass. The merge result with main is clean.

Follow-up, not a blocker: the DM tactical fact in combat-approach-service.ts:301 still says "with its"; the player does not see it.

Muse merges. Refs #1822 (item 3 is merged in #1825).


Generated by Claude Code

@Garblesnarff Garblesnarff left a comment

Copy link
Copy Markdown
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Strategist review — PASS at 7528ce6

CI: pull_request run 46344822773, green.

  • The second function is gone. The opportunity line is one describeResolvedAttack call with the Opportunity attack: prefix (player-exit-service.ts:237, :252). The (auto-rolled) note and the damage-parts sentence stay.
  • attack-narration.ts:39: "with ", first letter capital only ("Unarmed Strike", "Longsword", "+1 Dagger" unchanged; an empty name gives no phrase). No "with its" is left in player text.
  • Hit and miss unit tests are outside the real-DB suite. Three real-DB tests now assert the exact text (tighter, not looser).
  • Hero name (item 1) is unchanged since round 1.
  • Reviewer runs: client 61, server 32 pass. The merge result with main is clean.

Follow-up, not a blocker: the DM tactical fact in combat-approach-service.ts:301 still says "with its"; the player does not see it.

Muse merges. Refs #1822 (item 3 is merged in #1825).


Generated by Claude Code

@Garblesnarff
Garblesnarff marked this pull request as ready for review November 30, 2026 04:07
@Garblesnarff
Garblesnarff merged commit cb7d689 into main Nov 30, 2026
17 checks passed
@Garblesnarff
Garblesnarff deleted the fix/1822-hero-and-reaction-copy branch November 30, 2026 04:07
@Garblesnarff Garblesnarff mentioned this pull request Nov 30, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant