pub struct Board {
pub piece_bb: [Bitboard; 15],
pub pieces_in_hand: [[u8; 15]; 2],
pub occupied: [Bitboard; 2],
}Fields§
§piece_bb: [Bitboard; 15]§pieces_in_hand: [[u8; 15]; 2]§occupied: [Bitboard; 2]Implementations§
Source§impl Board
impl Board
pub fn empty() -> Self
pub fn move_between( &mut self, from: &Square, to: &Square, promote: bool, color: Color, ) -> Result<()>
pub fn push_move(&mut self, mv: Move) -> Result<MoveResult>
pub fn push_hand(&mut self, piece: Piece, color: Color)
pub fn remove_hand(&mut self, color: Color, piece: Piece) -> Result<()>
pub fn remove_piece(&mut self, sq: &Square, color: Color) -> Result<Piece>
pub fn push_piece(&mut self, sq: &Square, color: Color, piece: Piece)
pub fn generate_legal_moves(&self) -> Vec<LegalMove>
pub fn rotate180(&self) -> Self
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Board
impl RefUnwindSafe for Board
impl Send for Board
impl Sync for Board
impl Unpin for Board
impl UnwindSafe for Board
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more