chessground icon indicating copy to clipboard operation
chessground copied to clipboard

User request: one click move

Open Siderite opened this issue 1 year ago • 8 comments

I have a player who is disabled and can't use their fingers well. To them every click is a burden and drag and drop impossible. Therefore a way to click only once to move a piece is very useful.

The suggestion is to implement an additional optional mode of piece movement by clicking on a square and, if only one piece can legally move to that square, perform the move.

Siderite avatar Jun 28 '24 14:06 Siderite

this feature would really make life easier for me, and even for people that are just slow in using your mouse, this would definitely speed at things. I think doing puzzles and a more brisk flow could possibly help you recognize the structure thhe next time you see it. Also, if there are three different pieces that can go to that square, maybe give the user the option to pick one…?

Anyway, great idea!

pawndini avatar Dec 30 '24 21:12 pawndini

This is https://github.com/lichess-org/lila/issues/4738

TBestLittleHelper avatar Feb 14 '25 10:02 TBestLittleHelper

Because of chessground declared itself as "No chess logic inside", this feature completely belongs to lila (not here) IMO. I mean this library code has no info about valid moves nor unambiguous moves, so it is impossible to implement it here.

gbtami avatar Feb 14 '25 10:02 gbtami

chessground already has the concept of dests, right? Which are determined by the software using it, in this case Lila. So the code to determine the one click behavior, given each piece has the destinations defined, should be here.

Siderite avatar Feb 14 '25 11:02 Siderite

True. This may work for standard chess, but not for crazyhouse drop moves atm.

gbtami avatar Feb 14 '25 11:02 gbtami

I don't know what crazy chess does, but if it doesn't use dests, then it probably doesn't populate it, so you don't enable the feature. And if does populate dests, like in the case of "possible destinations for existing pieces" but you can also add pieces or something like that, then it's the responsibility of the using software to not enable single click move.

Siderite avatar Feb 14 '25 11:02 Siderite

To be honest, I've already implemented in LiChess Tools a hacky version of this for play/puzzles, but I have not enabled it because changing the way people play may be considered an unfair advantage. The version for Analysis works fine, though.

Anyway, the problem is that until Lila doesn't accept to make the effort to implement this, people like the player I mentioned cannot comfortably play chess. If the feature was available as an option in chessground, I am sure they would move on it, though.

Siderite avatar Feb 14 '25 11:02 Siderite

All the lichess games are using dests. Here is an example rnb1kbnr/ppp2ppp/8/3qp3/8/8/PPPP1PPP/RNBQKBNR/Pp w KQkq - 0 4 Chessground knows nothing about the pockets atm, so if you enable one click move, clicking on c4 square will move the white bishop there. But it would be possible to drop the pawn there as well. This is the problem I mentioned above.

gbtami avatar Feb 14 '25 13:02 gbtami