stagexl_interactive_chessboard 1.0.0 stagexl_interactive_chessboard: ^1.0.0 copied to clipboard
An interactive chessboard written for StageXL which allows players to move pieces.
StageXL Interactive Chessboard #
An interactive chessboard written for StageXL which allows players to move pieces.
Example #
Chessboard board = Chessboard();
stage.addChild(board);
It is fully compatible with chess.dart #
Chess.Chess chess = Chess.Chess()
..move("e3")
..move("e5")
..move("Qe2")
..move("d5");
board.loadFromChessObject(chess);
Any square can have its background color set #
board.resetAllSquareColors();
board.setSquareBackgroundColor("e1", 0xaa27b243);
Capture when squares are clicked #
board.onSquareClicked.listen((ChessEvent event) {
print(event.squareName);
});
Show and hide the labels around the board #
board.showLabels = true;
Change which way round the board is #
board.blackAtTop = false;