|
| enum | Player { P_EMPTY = 0
, P_YELLOW = 1
, P_RED = 2
} |
| using | TBitBoard = uint64_t |
| using | TMovesCounter = int |
| using | TBoardArray = std::array<std::array<int32_t, N_ROWS>, N_COLUMNS> |
| using | TBoardArrayT = std::array<std::array<int32_t, N_COLUMNS>, N_ROWS> |
|
| static constexpr int | popCountBoard (uint64_t x) |
| static uint64_t | hash (uint64_t x) |
| static TBitBoard | nextMove (TBitBoard allMoves) |
| static bool | isValid (const TBoardArray &board) |
| static TBitBoard | lsb (const TBitBoard x) |
| static std::pair< Board, std::vector< int > > | randomBoard (const int nPly, const bool forbidDirectWin=true) |
Definition at line 72 of file Board.h.
◆ TBitBoard
| using BitBully::Board::TBitBoard = uint64_t |
◆ TBoardArray
| using BitBully::Board::TBoardArray = std::array<std::array<int32_t, N_ROWS>, N_COLUMNS> |
◆ TBoardArrayT
| using BitBully::Board::TBoardArrayT = std::array<std::array<int32_t, N_COLUMNS>, N_ROWS> |
◆ TMovesCounter
| using BitBully::Board::TMovesCounter = int |
◆ Player
| enum BitBully::Board::Player |
◆ Board()
| BitBully::Board::Board |
( |
| ) |
|
◆ allPositions()
| std::vector< Board > BitBully::Board::allPositions |
( |
const int | upToNPly, |
|
|
bool | exactlyN ) const |
|
inlinenodiscard |
◆ canWin() [1/2]
| bool BitBully::Board::canWin |
( |
| ) |
const |
|
nodiscard |
◆ canWin() [2/2]
| bool BitBully::Board::canWin |
( |
int | column | ) |
const |
|
nodiscard |
◆ copy()
| Board BitBully::Board::copy |
( |
| ) |
const |
|
inlinenodiscard |
◆ countTokens()
| TMovesCounter BitBully::Board::countTokens |
( |
| ) |
const |
|
inlinenodiscard |
◆ doubleThreat()
| TBitBoard BitBully::Board::doubleThreat |
( |
const TBitBoard | moves | ) |
const |
|
inlinenodiscard |
◆ findOddThreats()
| Board::TBitBoard BitBully::Board::findOddThreats |
( |
TBitBoard | moves | ) |
|
◆ findThreats()
| Board::TBitBoard BitBully::Board::findThreats |
( |
TBitBoard | moves | ) |
|
◆ generateMoves()
| Board::TBitBoard BitBully::Board::generateMoves |
( |
| ) |
const |
|
nodiscard |
◆ generateNonLosingMoves()
| TBitBoard BitBully::Board::generateNonLosingMoves |
( |
| ) |
const |
|
inlinenodiscard |
◆ hash() [1/2]
| uint64_t BitBully::Board::hash |
( |
| ) |
const |
|
inlinenodiscard |
◆ hash() [2/2]
| uint64_t BitBully::Board::hash |
( |
uint64_t | x | ) |
|
|
inlinestatic |
◆ hasWin()
| bool BitBully::Board::hasWin |
( |
| ) |
const |
|
nodiscard |
◆ isLegalMove()
| bool BitBully::Board::isLegalMove |
( |
int | column | ) |
const |
|
nodiscard |
◆ isValid()
| bool BitBully::Board::isValid |
( |
const TBoardArray & | board | ) |
|
|
static |
◆ lsb()
| TBitBoard BitBully::Board::lsb |
( |
const TBitBoard | x | ) |
|
|
inlinestatic |
◆ mirror()
| Board BitBully::Board::mirror |
( |
| ) |
const |
|
nodiscard |
◆ movesLeft()
| TMovesCounter BitBully::Board::movesLeft |
( |
| ) |
const |
|
inlinenodiscard |
◆ nextMove()
| TBitBoard BitBully::Board::nextMove |
( |
TBitBoard | allMoves | ) |
|
|
inlinestatic |
◆ operator!=()
| bool BitBully::Board::operator!= |
( |
const Board & | b | ) |
const |
|
inline |
◆ operator==()
| bool BitBully::Board::operator== |
( |
const Board & | b | ) |
const |
|
inline |
◆ playMove()
| bool BitBully::Board::playMove |
( |
int | column | ) |
|
◆ playMoveFastBB()
| void BitBully::Board::playMoveFastBB |
( |
const TBitBoard | mv | ) |
|
|
inline |
◆ playMoveOnCopy()
| Board BitBully::Board::playMoveOnCopy |
( |
const TBitBoard | mv | ) |
const |
|
inlinenodiscard |
◆ popCountBoard() [1/2]
| auto BitBully::Board::popCountBoard |
( |
| ) |
const |
|
inlinenodiscard |
◆ popCountBoard() [2/2]
| constexpr int BitBully::Board::popCountBoard |
( |
uint64_t | x | ) |
|
|
inlinestaticconstexpr |
◆ randomBoard()
| std::pair< Board, std::vector< int > > BitBully::Board::randomBoard |
( |
const int | nPly, |
|
|
const bool | forbidDirectWin = true ) |
|
inlinestatic |
◆ setBoard() [1/4]
| bool BitBully::Board::setBoard |
( |
const std::string & | moveSequence | ) |
|
◆ setBoard() [2/4]
| bool BitBully::Board::setBoard |
( |
const std::vector< int > & | moveSequence | ) |
|
◆ setBoard() [3/4]
| bool BitBully::Board::setBoard |
( |
const TBoardArray & | board | ) |
|
◆ setBoard() [4/4]
| bool BitBully::Board::setBoard |
( |
const TBoardArrayT & | board | ) |
|
◆ sortMoves()
| MoveList BitBully::Board::sortMoves |
( |
TBitBoard | moves | ) |
const |
|
nodiscard |
◆ toArray()
| Board::TBoardArray BitBully::Board::toArray |
( |
| ) |
const |
|
nodiscard |
◆ toHuffman()
| int BitBully::Board::toHuffman |
( |
| ) |
const |
|
inlinenodiscard |
◆ toString()
| std::string BitBully::Board::toString |
( |
| ) |
const |
|
nodiscard |
◆ uid()
| uint64_t BitBully::Board::uid |
( |
| ) |
const |
|
inlinenodiscard |
◆ BoardTest
◆ COLUMN_BIT_OFFSET
| int BitBully::Board::COLUMN_BIT_OFFSET = 9 |
|
staticconstexpr |
◆ N_COLUMNS
| int BitBully::Board::N_COLUMNS = 7 |
|
staticconstexpr |
◆ N_ROWS
| int BitBully::Board::N_ROWS = 6 |
|
staticconstexpr |
◆ N_VALID_BOARD_VALUES
| size_t BitBully::Board::N_VALID_BOARD_VALUES = 3 |
|
staticconstexpr |
The documentation for this class was generated from the following files: