test: movegen tool
This commit is contained in:
parent
611cdd4d51
commit
1b250f224d
16
src/bin/movegen_tool.rs
Normal file
16
src/bin/movegen_tool.rs
Normal file
@ -0,0 +1,16 @@
|
|||||||
|
//! Generates moves from the FEN in the argv.
|
||||||
|
|
||||||
|
use chess_inator::Board;
|
||||||
|
use chess_inator::fen::FromFen;
|
||||||
|
use chess_inator::movegen::LegalMoveGen;
|
||||||
|
use std::env;
|
||||||
|
|
||||||
|
fn main() {
|
||||||
|
for arg in env::args().skip(2) {
|
||||||
|
let board = Board::from_fen(&arg).unwrap();
|
||||||
|
let mvs = board.gen_moves();
|
||||||
|
for mv in mvs.into_iter() {
|
||||||
|
println!("{mv:?}")
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
Loading…
Reference in New Issue
Block a user