Add TT lookups in quiescence, move TT inside Game, remove redundant occupancy and time limit functions
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
use crate::{
|
||||
board::fen::from_fen,
|
||||
movegen::r#move::{Move, MoveType},
|
||||
search::{transposition_table::TranspositionTable, MAX_TT_SIZE},
|
||||
};
|
||||
use String as FenError;
|
||||
|
||||
@@ -27,15 +28,17 @@ pub struct Game {
|
||||
pub history: History,
|
||||
pub mailbox: Mailbox,
|
||||
pub hash: ZobristHash,
|
||||
pub tt: TranspositionTable,
|
||||
}
|
||||
|
||||
impl Game {
|
||||
pub fn new() -> Self {
|
||||
Self {
|
||||
board: Board::new(),
|
||||
board: Board::startpos(),
|
||||
history: History::new(),
|
||||
mailbox: Mailbox::from_board(&Board::new()),
|
||||
hash: zobrist_keys().calculate_hash(&Board::new()),
|
||||
mailbox: Mailbox::from_board(&Board::startpos()),
|
||||
hash: zobrist_keys().calculate_hash(&Board::startpos()),
|
||||
tt: TranspositionTable::new(MAX_TT_SIZE),
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user