BenBot 1.7.5
A chess engine
Loading...
Searching...
No Matches
chess::moves::pseudo_legal Namespace Reference

Classes

struct  Bitboard

Enumerations

enum class  Color

Functions

template<Color Side>
constexpr auto pawn_pushes (Bitboard startingPawns, Bitboard emptySquares) noexcept -> Bitboard
template<Color Side>
constexpr auto pawn_double_pushes (Bitboard startingPawns, Bitboard occupiedSquares) noexcept -> Bitboard
template<Color Side>
constexpr auto pawn_captures (Bitboard startingPawns, Bitboard enemyPieces) noexcept -> Bitboard
constexpr auto knight (Bitboard startingKnights, Bitboard friendlyPieces) noexcept -> Bitboard
constexpr auto bishop (Bitboard startingBishops, Bitboard emptySquares, Bitboard friendlyPieces) noexcept -> Bitboard
constexpr auto rook (Bitboard startingRooks, Bitboard emptySquares, Bitboard friendlyPieces) noexcept -> Bitboard
constexpr auto queen (Bitboard startingQueens, Bitboard emptySquares, Bitboard friendlyPieces) noexcept -> Bitboard
constexpr auto king (Bitboard startingKing, Bitboard friendlyPieces) noexcept -> Bitboard

Detailed Description

This namespace provides functions for generating pseudo-legal moves for each piece type from a given starting position. These functions rely on other board state, such as sets of empty or occupied squares, etc. The generated moves are pseudo-legal, not strictly legal, because they do not consider whether the king would be left in check. The returned move sets do not include the starting square.

Enumeration Type Documentation

◆ Color

enum class chess::pieces::Color : std::uint_fast8_t
strong

This enum identifies the side to move.

Definition at line 29 of file Colors.hpp.