Struct poirebot::game::BoardSide [−][src]
Fields
color: Color
pawns: BitBoard
Where all this side’s pawns are.
rooks: BitBoard
Where all this side’s rooks are.
knights: BitBoard
Where all this side’s knights are.
bishops: BitBoard
Where all this side’s bishops are.
queens: BitBoard
Where all this side’s queens are.
king: BitBoard
Where this side’s king is.
unmoved_rooks: BitBoard
Rooks that haven’t moved.
en_passant_target: BitBoard
Pawn that could get en-passant’d in the next turn.
pieces: BitBoard
Inherited; Where all this side’s pieces are.
attacks: BitBoard
Inherited; squares attacked by this side’s pieces.
king_has_moved: bool
Whether the king has already moved.
Implementations
impl BoardSide
[src]
pub fn get_piece(&self, position: Position) -> Option<Pieces>
[src]
Get the piece at the given position if any.
pub fn flip(&self) -> Self
[src]
Return a new instance for the other side.
pub fn new<F: FnOnce(&mut Self)>(color: Color, f: F) -> Self
[src]
Initialize a new side (empty at first) and then refresh inherited properties.
pub fn mutate<F: FnOnce(&mut Self)>(&mut self, f: F)
[src]
Mutates and then refresh inherited properties.
Trait Implementations
impl Clone for BoardSide
[src]
impl Copy for BoardSide
[src]
impl Debug for BoardSide
[src]
impl Eq for BoardSide
[src]
impl PartialEq<BoardSide> for BoardSide
[src]
impl StructuralEq for BoardSide
[src]
impl StructuralPartialEq for BoardSide
[src]
Auto Trait Implementations
impl RefUnwindSafe for BoardSide
impl Send for BoardSide
impl Sync for BoardSide
impl Unpin for BoardSide
impl UnwindSafe for BoardSide
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> Pointable for T
pub const ALIGN: usize
type Init = T
The type for initializers.
pub unsafe fn init(init: <T as Pointable>::Init) -> usize
pub unsafe fn deref<'a>(ptr: usize) -> &'a T
pub unsafe fn deref_mut<'a>(ptr: usize) -> &'a mut T
pub unsafe fn drop(ptr: usize)
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
pub fn to_owned(&self) -> T
[src]
pub fn clone_into(&self, target: &mut T)
[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
pub fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
V: MultiLane<T>,