Repository navigation
Clearpath cutoff display - #528
Merged
Perlkonig merged 3 commits intoNov 17, 2026
Merged
Conversation
… a line
A player reported a finished game in which the "highlighted path" ran through
a crosscut. The game had ended by cut-off (the loser had no possible connecting
path left), and the board drew the sealing chain of the winner's stones, which
may step diagonally, as a line, so it looked like a claimed winning path.
- After a cut-off the sealing stones are now ringed (`exit` annotation, shape
circle, solid) and no line is drawn. A completed winning path is still drawn
as a line.
- The game description states the cut-off ending, and the move-log line for it
now reads "{{player}} no longer has any possible connecting path. The ringed
stones cut {{player}} off."
- Game version 20261117. Tests: the reported position (reached by a legal move
sequence) and the ring/line distinction; 18 tests pass, full suite 2633 pass,
typecheck, eslint and locale checks clean, 10,943 render JSONs of random games
validated against the renderer schema.
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_017npPuLb95uaXUHuPGvTT1b
…e sealing chain
Replaces the rings of the previous commit. After a cut-off win the board now
draws one of the winner's remaining possible connections (the one needing the
fewest further stones, orthogonal steps only, so it never passes a crosscut) as
a dashed line, with the stones still to be placed drawn faintly (legend glyphs
with opacity 0.35). A completed winning path is still drawn as a solid line.
The move-log line for the cut-off ending now reads "{{player}} no longer has
any possible connection, so {{winner}} cannot be stopped. The dashed line shows
one of the possible connections still open to {{winner}}."
New helper cpPossibleConnection (0-1 breadth-first search). Tests cover the
route chosen for two cut-off positions, the faint stones, and random play;
19 tests pass, typecheck, eslint and locale checks clean, 10,943 render JSONs
of random games validated against the renderer schema.
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_017npPuLb95uaXUHuPGvTT1b
The random-play test compared the faint stones (listed row by row) with the unoccupied points of the dashed route (listed edge to edge), which only agree by chance. Compare them sorted. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_017npPuLb95uaXUHuPGvTT1b
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
After a cut-off win (a placement that leaves the opponent without any possible connection) the board drew the winner’s sealing chain as a line, and the chain may step diagonally, so a player reported a “winning path through crosscuts”. The board now draws one of the winner’s remaining possible connections as a dashed line, orthogonal steps only, with the stones still to be placed shown faintly. A completed winning path is still a solid line. The move log names the winner and the dashed line, and the game description states the cut-off ending. Game version 20261117. Three commits (rings, then the dashed line, then a test fix); squash if you prefer.