shakmaty
A Rust library for chess move generation
Features
-
Generate legal moves:
use Chess; use Position; use MoveList; let pos = default; // starting position let mut legals = new; pos.legal_moves; assert_eq!;
-
Play moves:
use Move; use Role; use square; let pos = pos.play.expect;
-
Detect game end conditions:
pos.is_checkmate()
,pos.is_stalemate()
,pos.is_insufficient_material()
,pos.outcome()
. -
Read and write FENs, SANs and UCIs.
-
Supports Standard chess and these variants: Crazyhouse, King Of The Hill, Giveaway, ThreeCheck, Horde, Atomic, and RacingKings.
-
Bitboards and PDEP attack tables.
Documentation
License
Shakmaty is licensed under the GPL-3.0 (or any later version at your option). See the COPYING file for the full license text.