arimaa-engine 0.1.0

A bitboard-based Arimaa game engine: move generation, game state, and Zobrist hashing.
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
#[macro_export]
macro_rules! take_actions {
    ($($action: expr),* $(,)?) => {{
        take_actions![GameState::initial() => $($action),*]
    }};
    ($game_state: expr => $($action: expr),*) => {{
        let mut game_state = $game_state;
        $({
            let action = <$crate::Action as std::str::FromStr>::from_str(stringify!($action)).unwrap();
            game_state = game_state.take_action(&action);
        })*
        game_state
    }};
}