My Project
Classes | Static Public Member Functions | List of all members
osl::checkmate::CheckmateIfCapture Struct Reference

#include <checkmateIfCapture.h>

Classes

struct  CallDefense
 

Static Public Member Functions

static bool effectiveAttack (NumEffectState &state, Move move, int depth)
 move を指した後,alt(move.player())が取ると詰みかどうか. More...
 
static bool cannotCapture (NumEffectState &state, Square last_to, int depth)
 手番の側がSquare の駒を取っても詰みがないか. More...
 
static bool effectiveAttackCandidate0 (const NumEffectState &state, Move move)
 depth==0でeffectiveAttackになる可能性がなければfalse More...
 

Detailed Description

Definition at line 13 of file checkmateIfCapture.h.

Member Function Documentation

◆ cannotCapture()

bool osl::checkmate::CheckmateIfCapture::cannotCapture ( NumEffectState state,
Square  last_to,
int  depth 
)
static

◆ effectiveAttack()

bool osl::checkmate::CheckmateIfCapture::effectiveAttack ( NumEffectState state,
Move  move,
int  depth 
)
static

move を指した後,alt(move.player())が取ると詰みかどうか.

  • alt(move.player()) から利きがない場合はfalse
  • 取る指手が全て取ると詰の場合は true
    Parameters
    depth0 なら ImmediateCheckmate のみ,2なら3手詰.

Definition at line 119 of file checkmateIfCapture.cc.

References osl::NumEffectState::makeUnmakeMove(), osl::Move::player(), osl::checkmate::CheckmateIfCapture::CallDefense::result, and osl::SimpleState::turn().

Referenced by osl::move_probability::CheckmateIfCapture::hasSafeCapture(), and osl::rating::CheckmateIfCapture::match().

◆ effectiveAttackCandidate0()

bool osl::checkmate::CheckmateIfCapture::effectiveAttackCandidate0 ( const NumEffectState state,
Move  move 
)
static

depth==0でeffectiveAttackになる可能性がなければfalse

Definition at line 20 of file checkmateIfCapture.cc.

References osl::alt(), osl::PieceMask::any(), osl::Board_Table, osl::Piece::canMoveOn(), osl::captured(), osl::Move::capturePtype(), osl::NumEffectState::countEffect(), osl::checkmate::King8Info::dropCandidate(), osl::NumEffectState::effectSetAt(), osl::Move::from(), osl::effect_util::Neighboring8Direct::hasEffect(), osl::NumEffectState::hasEffectAt(), osl::NumEffectState::hasEffectByPiece(), osl::NumEffectState::hasEffectByPtypeStrict(), osl::NumEffectState::hasEffectNotBy(), osl::effect_util::Neighboring8Direct::hasEffectOrAdditional(), osl::SimpleState::hasPieceOnStand(), osl::NumEffectState::inCheck(), osl::Move::isCapture(), osl::Move::isDrop(), osl::Piece::isEdge(), osl::Piece::isEmpty(), osl::Square::isNeighboring8(), osl::Piece::isOnBoardByOwner(), osl::NumEffectState::king8Info(), osl::SimpleState::kingSquare(), osl::KNIGHT, osl::checkmate::King8Info::liberty(), osl::NumEffectState::longEffectAt(), osl::checkmate::King8Info::moveCandidate2(), osl::BoardTable::nextSquare(), osl::container::PieceMask64::none(), osl::SimpleState::pieceAt(), osl::SimpleState::pieceOf(), osl::SimpleState::pieceOnBoard(), osl::NumEffectState::piecesOnBoard(), osl::Piece::ptypeO(), osl::Piece::square(), osl::container::PieceMask64::takeOneBit(), osl::Move::to(), osl::SimpleState::turn(), osl::unpromote(), osl::UUL, and osl::UUR.

Referenced by osl::rating::CheckmateIfCapture::match().


The documentation for this struct was generated from the following files: