flutter_chess_board
flutter_chess_board copied to clipboard
Complex handling movements subscription
Currently, a move event is generated after calling ChessBoardController.makeMoveWithPromotion or ChessBoardController.makeMove, even if the move is invalid. This causes subscribers to receive notifications for rejected moves, forcing client-side logic to handle both valid and invalid moves.
Proposed solutions:
- Include additional information in the event indicating whether the move was accepted or rejected.
- Introduce separate streams, such as approvedMovementsStream and rejectedMovementsStream.