giga-chess 0.4.0

A rust chess library built for performance, handling game logic and legal/best move generation.
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
pub const COLORS: [Color; 2] = [Color::White, Color::Black];

#[derive(Debug, Copy, Clone, Eq, PartialEq)]
pub enum Color {
    White = 0,
    Black = 1,
}

impl Color {
    pub fn opposite(self) -> Color {
        match self {
            Color::White => Color::Black,
            Color::Black => Color::White,
        }
    }
}