[Board] Move DefinedBoards to BitBoard
This commit is contained in:
18
BitBoard.h
18
BitBoard.h
@@ -3,9 +3,27 @@
|
||||
|
||||
#include <cstdint>
|
||||
#include <ostream>
|
||||
#include "Square.hpp"
|
||||
|
||||
enum DefinedBoards : uint64_t {
|
||||
AFile = 0x0101010101010101,
|
||||
BFile = AFile << 1,
|
||||
CFile = AFile << 2,
|
||||
DFile = AFile << 3,
|
||||
EFile = AFile << 4,
|
||||
FFile = AFile << 5,
|
||||
GFile = AFile << 6,
|
||||
HFile = AFile << 7,
|
||||
WhiteCastlingRank = (1ULL << A2) - 1,
|
||||
BlackCastlingRank = (~1ULL << H7),
|
||||
CastlingRanks = WhiteCastlingRank | BlackCastlingRank,
|
||||
CastlingSquares = (WhiteCastlingRank | BlackCastlingRank) & (CFile | GFile),
|
||||
};
|
||||
|
||||
class BitBoard final {
|
||||
|
||||
public:
|
||||
|
||||
using U64 = uint64_t;
|
||||
|
||||
BitBoard(U64 v = 0);
|
||||
|
Reference in New Issue
Block a user