lichess-org / flutter-chessground

Chessboard package for flutter
https://pub.dev/packages/chessground
GNU General Public License v3.0
43 stars 28 forks source link

Premoves in free play? #41

Open sorsted opened 1 month ago

sorsted commented 1 month ago

I would like to enable premoves for both sides in free play. I tried setting interactibleSide to InteractableSide.both, but this did not do the trick.

I found the issue, by the way: At lines 382 and 774 of the file Board.dart, you should check for the possibility that widget.data.interactableSide is set to InteractableSide.both.

veloce commented 1 month ago

I'm not sure there is a use case for this.

Can you precise what is yours? Thanks.

sorsted commented 1 month ago

Local games where you are allowed to premove.

In any case, the current solution where making both sides interactable turns off premoves for both sides is very confusing and inconsistent. And changing it only requires updating two lines of code.