Skip to content

Releases: jwyce/gungi.js

v3.4.11

03 Mar 23:15
94447b7

Choose a tag to compare

Patch Changes

  • 8aae510: Allow tactician betrayal move generation when moving onto a friendly-topped tower with enemy pieces underneath.

    • Generate 謀(... )返X for onboard tactician stacks with convertible enemy pieces below a friendly top piece.
    • Preserve existing arata betrayal behavior.
    • Add regression coverage for onboard betray generation and execution.

v3.4.10

03 Mar 20:11
1398dfa

Choose a tag to compare

Patch Changes

  • 941567b: Fix tactician arata betrayal generation when stacking onto a friendly-topped tower.

    • Allow 新謀(... )返X move generation for this niche arata case.
    • Apply betrayal conversion and hand consumption correctly for arata betrayal moves.
    • Add regression coverage for both white and black variants.

v3.4.9

02 Mar 04:14
b91193d

Choose a tag to compare

Patch Changes

  • 30ed821: Restrict leap-over behavior for jumping pieces to forward movement only.

    • Cannon, archer, and musketeer can no longer jump over blockers when moving sideways or backward.
    • Added movement regression tests that verify forward leaps remain legal and non-forward leaps are blocked.

v3.4.8

01 Mar 03:25
752c344

Choose a tag to compare

Patch Changes

  • 1c85b94: Fix two core rules in move generation and draft flow.

    • End draft as soon as black selects ; white selecting only ends white drafting rights.
    • Correct archer diagonals so a higher tower on either side wing blocks that full diagonal.

v3.4.7

29 Jan 22:12
f6b133f

Choose a tag to compare

Patch Changes

  • 4d1554c: Fix draft phase softlock when player has only 1 piece left in hand

v3.4.6

26 Jan 14:32
c92b85e

Choose a tag to compare

Patch Changes

  • cd851e5: Fix checkmate and stalemate detection to follow Gungi-specific rules

    • Checkmate: Now correctly detects when a player is in check AND has no move that would escape check. In Gungi, players CAN move while in check (unlike chess), but checkmate occurs when no move escapes.
    • Stalemate: Now correctly detects when a player is NOT in check but ALL possible moves would result in being in check. This is a draw condition.
    • Insufficient Material: Added detection for draw when only two non-adjacent marshals remain on the board (no other pieces in play or in hand).
    • isGameOver(): Updated to include stalemate and insufficient material as game-ending conditions alongside marshal capture, checkmate, and fourfold repetition.
    • isDraw(): Now returns true for stalemate, fourfold repetition, or insufficient material.
  • cd851e5: Append "=" suffix to SAN notation for insufficient material draws

    Previously, the move() function only appended "=" for stalemate and fourfold repetition draws. Now it also appends "=" when a move results in insufficient material (only two non-adjacent marshals remaining).

v3.4.5

25 Jan 21:31
e796478

Choose a tag to compare

Patch Changes

  • bf7a793: Fix checkmate and stalemate detection to follow Gungi-specific rules

    • Checkmate: Now correctly detects when a player is in check AND has no move that would escape check. In Gungi, players CAN move while in check (unlike chess), but checkmate occurs when no move escapes.
    • Stalemate: Now correctly detects when a player is NOT in check but ALL possible moves would result in being in check. This is a draw condition.
    • Insufficient Material: Added detection for draw when only two non-adjacent marshals remain on the board (no other pieces in play or in hand).
    • isGameOver(): Updated to include stalemate and insufficient material as game-ending conditions alongside marshal capture, checkmate, and fourfold repetition.
    • isDraw(): Now returns true for stalemate, fourfold repetition, or insufficient material.

v3.4.4

06 Jan 17:06
5eddeed

Choose a tag to compare

Patch Changes

  • a5e7b1a: consistent last san notation (ensures # or =) on final move

v3.4.3

04 Jan 22:42
6539d67

Choose a tag to compare

Patch Changes

  • 66a2f4d: The fix adds arata detection to assignIdsWithPositionMatching - when stepping through moves without explicit move info

v3.4.2

04 Jan 22:11
7698d55

Choose a tag to compare

Patch Changes

  • 064b2fa: fix arata piece id assignment for accurate tracking (useful for animated presence)