ianfab / fairyground

playground for Fairy-Stockfish in the browser
https://fairyground.vercel.app/
GNU General Public License v3.0
20 stars 5 forks source link

Null Move & WallOrMove Support & Fixes #79

Closed yjf2002ghty closed 1 month ago

yjf2002ghty commented 1 month ago

New Features

  1. Added null move support. Users can double click a square to make a null move on that square.
  2. Added Wall Or Move support for Atlantis and other variants that uses this rule. (Reported via Discord)

Fixes

  1. Fixed the display bug that being unable to display wall gating moves on \<Highlight Move> button in "Show moves dialog" section.
  2. Remove the redundant part of wall gating selection. Now users only need to provide the destination square.
vercel[bot] commented 1 month ago

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
fairyground ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jun 4, 2024 6:25am
ianfab commented 1 month ago

Thanks! Just a small comment regarding terminology. For moves that do nothing there are the two terms pass and null move. Due to the contexts they are usually used for I try to consistently refer to such moves as passes when actually appearing in a game, and as null moves when they are hypothetical skips of turns, e.g., in the context of null move pruning or for analysis purposes in games where passing is not actually allowed.

yjf2002ghty commented 1 month ago

wallOrMove rule uses wall gating syntax like a1a1,a1a3 to gate a wall only on square a3. The a1a1 is not an actual move, but it's also not a pass. Therefore I don't know how to call that. This pull request is intended to support making the a1a1 part on the board so that users can select the square they want to gate the wall. I don't know how to call this action, so null move is chosen.

In my opinion pass means making no changes to the board. However if a multi-leg move contains a move like a1a1, I will call it a null move.

ianfab commented 1 month ago

Right, in this context it is rather an artifact of the move representation than a pass, so null move makes sense indeed.