fix start posytion; some test
This commit is contained in:
1 parent
54c458296d
commit
2c2ccd6770
2 files changed
+11
-21
No files matched your search
+6
-20
@@ -1,32 +1,18 @@
|
||||
mod chess_api;
|
||||
use chess_api::board::*;
|
||||
use chess_api::*;
|
||||
|
||||
mod render_bitmask;
|
||||
use render_bitmask::*;
|
||||
|
||||
fn main() {
|
||||
|
||||
let full: u64 = 0xfefefefefefefefe;
|
||||
let mut game: Breakthrough = Breakthrough::new();
|
||||
|
||||
let own: u64 = 0xffff002100000000;
|
||||
let b = game.get_board();
|
||||
|
||||
let wr: u64 = 0x000000000004c83b;
|
||||
println!("move: {}", game.legal_moves().len());
|
||||
|
||||
let bish: u64 = 0x0000002100000000;
|
||||
render_board(BoardColor::Solid('~'), vec![(b.get_mask(Color::White, 0), 'W'), (0xff << 56, 'f')]);
|
||||
|
||||
let ans: u64 = trajectory(bish, full, own, wr, -7, None);
|
||||
|
||||
render_board(BoardColor::Solid(':'), vec![(ans & wr,'t'), (ans, 'm'), (bish, 'a')]);
|
||||
|
||||
print!("\n");
|
||||
|
||||
render_board(BoardColor::Solid(':'), vec![(wr, 'k'), (own, 'w')]);
|
||||
|
||||
print!("\n");
|
||||
|
||||
render_board(BoardColor::Solid('`'), vec![(!mov_mask(3), 'a'), (!mov_mask(-2), 'c')]);
|
||||
|
||||
print!("\n");
|
||||
|
||||
render_board(BoardColor::Solid('`'), vec![(0xffff, 'W'), (0xffff << 48, 'B')]);
|
||||
println!("move: {:?}", game.legal_moves());
|
||||
}
|
||||
Reference in new issue
Block a user