diff options
| author | Adam <adammegarules1@gmail.com> | 2026-07-31 12:11:58 +0200 |
|---|---|---|
| committer | Adam <adammegarules1@gmail.com> | 2026-07-31 12:11:58 +0200 |
| commit | a550620aa894e218a738b62b9ecd042b03f7858f (patch) | |
| tree | 5d6f459e9db0a6f315c6d1e1e7f54cd1feade724 /src/board | |
| parent | 17f245ac325cea859fb39799a9c8b088fc933808 (diff) | |
changes
Diffstat (limited to 'src/board')
| -rw-r--r-- | src/board/board.hpp | 23 |
1 files changed, 14 insertions, 9 deletions
diff --git a/src/board/board.hpp b/src/board/board.hpp index 0b92798..d1e379a 100644 --- a/src/board/board.hpp +++ b/src/board/board.hpp @@ -32,9 +32,23 @@ struct Position { bool operator==(const Position &) const = default; }; +struct Move { + Position From; + Position To; + + PieceType promotion = NONEPIECE; + bool operator==(const Move &other) const { + return From == other.From && To == other.To && promotion == other.promotion; + } +}; + +enum Flag { EXACT, LOWERBOUND, UPPERBOUND }; + struct TranspositionsEntry { int depth; int Eval; + Flag flag; + Move bestMove = {}; }; struct Game { Piece pieces[64]; @@ -52,15 +66,6 @@ struct Game { std::unordered_map<uint64_t, TranspositionsEntry> *Transpositions = nullptr; }; -struct Move { - Position From; - Position To; - - PieceType promotion = NONEPIECE; - bool operator==(const Move &other) const { - return From == other.From && To == other.To && promotion == other.promotion; - } -}; struct UndoMove { Piece movedPiece; Piece capturedPiece; |
