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())が取ると詰みかどうか.
 
static bool cannotCapture (NumEffectState &state, Square last_to, int depth)
 手番の側がSquare の駒を取っても詰みがないか.
 
static bool effectiveAttackCandidate0 (const NumEffectState &state, Move move)
 depth==0でeffectiveAttackになる可能性がなければfalse
 

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

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