駒. More...
#include <piece.h>
Public Member Functions | |
int | intValue () const |
Piece (Player owner, Ptype ptype, int num, Square square) | |
Piece () | |
Ptype | ptype () const |
PtypeO | ptypeO () const |
int | number () const |
const Square | square () const |
Piece & | operator+= (Offset offset) |
void | setSquare (Square square) |
template<Player P> | |
bool | isOnBoardByOwner () const |
piece がプレイヤーPの持ち物でかつボード上にある駒の場合は true. More... | |
bool | isOnBoardByOwner (Player owner) const |
isOnBoardByOwner の通常関数のバージョン. More... | |
const Piece | promote () const |
const Piece | unpromote () const |
const Piece | captured () const |
取られたpieceを作成. More... | |
const Piece | promoteWithMask (int promote_mask) const |
const Piece | checkPromote (bool promotep) const |
bool | isPromoted () const |
promoteした駒かどうかをチェックする More... | |
bool | isOnBoardNotPromoted () const |
promoteしていないOnBoardの駒であることのチェック Lance位しか使い道がない? More... | |
bool | isPromotedNotKingGold () const |
bool | isEmpty () const |
bool | isEdge () const |
template<Ptype T> | |
bool | isPtype () const |
bool | isPlayerPtype (Player pl, Ptype ptype) const |
あるpieceがPlayer pの持ち物でPtype ptypeであるかどうかをチェックする. TはEMPTY, EDGEではない. More... | |
bool | isPlayerBasicPtype (Player pl, Ptype ptype) const |
あるpieceがPlayer pの持ち物でBASIC typeがptypeであるかどうかをチェックする. TはEMPTY, EDGEではない. More... | |
bool | isPiece () const |
bool | pieceIsBlack () const |
pieceであることが分かっている時に,更にBlackかどうかをチェックする. More... | |
Player | owner () const |
template<Player P> | |
bool | canMoveOn () const |
Player Pの駒が,thisの上に移動できるか? More... | |
bool | canMoveOn (Player pl) const |
bool | isOnBoard () const |
Static Public Member Functions | |
static const Piece | makeDirect (int value) |
static const Piece | EMPTY () |
static const Piece | EDGE () |
static const Piece | makeKing (Player owner, Square square) |
玉を作る More... | |
static bool | isEmptyNum (int num) |
static bool | isEdgeNum (int num) |
static bool | isPieceNum (int num) |
Static Public Attributes | |
static const int | SIZE =40 |
static const int | BitOffsetPtype =16 |
static const int | BitOffsetPromote =BitOffsetPtype+3 |
static const int | BitOffsetMovePromote =BitOffsetPromote+4 |
Private Member Functions | |
Piece (int p) | |
bool | isOnBoardByOwner (Int2Type< BLACK >) const |
bool | isOnBoardByOwner (Int2Type< WHITE >) const |
opteronでは, return static_cast<int>((piece+0x80000000)&0x800000ff)>0; の方が速かった. More... | |
bool | canMoveOn (Int2Type< BLACK >) const |
PIECE_EMPTY 0x00008000 BLACK_PIECE 0x000XxxYY X>=2, YY>0 PIECE_EDGE 0xfff14000 WHITE_PIECE 0xfffXxxYY X>=2, YY>0. More... | |
bool | canMoveOn (Int2Type< WHITE >) const |
Private Attributes | |
int | piece |
駒.
駒はptypeo(-15 - 15), 番号(0-39), ポジション(0-0xff)からなる 上位16 bitでptypeo, 8bitで番号, 8bitでポジションとする. 空きマスは 黒,PTYPE_EMPTY, 番号 0x80, ポジション 0 盤外は 白,PTYPE_EDGE, 番号 0x40, ポジション 0
|
inline |
Definition at line 44 of file piece.h.
Referenced by captured(), checkPromote(), EDGE(), EMPTY(), makeDirect(), makeKing(), promote(), promoteWithMask(), and unpromote().
|
inlineprivate |
PIECE_EMPTY 0x00008000 BLACK_PIECE 0x000XxxYY X>=2, YY>0 PIECE_EDGE 0xfff14000 WHITE_PIECE 0xfffXxxYY X>=2, YY>0.
Definition at line 223 of file piece.h.
References piece.
Referenced by osl::checkmate::detail::blockingDiagonalAttack(), osl::move_generator::detail::blockingU(), osl::checkmate::detail::blockingVerticalAttack(), osl::eval::ml::SilverFeatures::canRetreat(), osl::eval::ml::KnightAdvance::cantAdvance(), osl::rating::Threatmate::captureForKnightCheck(), osl::checkmate::CheckmateIfCapture::effectiveAttackCandidate0(), osl::eval::ml::RookPromoteDefense::eval(), osl::move_generator::detail::generateBishopLongMove(), osl::move_generator::detail::generateBishopLongMoveNotKing(), osl::move_generator::detail::generateDirNotKing(), osl::move_generator::promote::AllPromoteDir< P, T, noCapture, Dir >::generateIfValid(), osl::move_generator::promote::MayPromoteDir< P, T, noCapture, Dir >::generateIfValid(), osl::move_generator::piece_on_board::generateKingDir(), osl::move_generator::detail::generateKnightDir(), osl::move_generator::piece_on_board::generateLance(), osl::move_generator::piece_on_board::generateLong(), osl::move_generator::without_effect::generateLongMove(), osl::move_generator::piece_on_board::generatePawn(), osl::move_generator::detail::generateRookLongMove(), osl::move_generator::detail::generateRookLongMoveNotKing(), osl::move_generator::piece_on_board::generateShort(), osl::checkmate::King8Info::hasEffectMask(), osl::checkmate::detail::hasKnightCheckmate(), osl::move_classifier::TrapRook< P >::isMember(), osl::container::NearMask::make(), osl::eval::ml::SilverFork::matchGold(), and osl::move_classifier::TrapRook< P >::testDirection().
|
inlineprivate |
|
inline |
Player Pの駒が,thisの上に移動できるか?
P | 手番 |
Definition at line 235 of file piece.h.
References canMoveOn().
Referenced by canMoveOn().
|
inline |
Definition at line 237 of file piece.h.
References osl::BLACK.
|
inline |
取られたpieceを作成.
unpromoteして,Squareは0に 相手の持ちものにする
Definition at line 126 of file piece.h.
References piece, and Piece().
Referenced by osl::state::NumEffectState::prologueCapture(), and osl::eval::endgame::AttackDefense::updateKingMove().
|
inline |
|
inlinestatic |
Definition at line 33 of file piece.h.
References osl::EDGE_NUM, Piece(), osl::PTYPE_EDGE, osl::Square::STAND(), and osl::WHITE.
Referenced by osl::rating::PatternBlock::find().
|
inlinestatic |
Definition at line 32 of file piece.h.
References osl::BLACK, osl::EMPTY_NUM, Piece(), osl::PTYPE_EMPTY, and osl::Square::STAND().
Referenced by osl::move_generator::escape::blockByMoveOne(), osl::state::NumEffectState::epilogueDrop(), osl::state::NumEffectState::epilogueSimple(), osl::eval::ppair::PiecePairEval< Eval, Table >::expect(), osl::state::NumEffectState::findAttackAt(), osl::state::NumEffectState::findAttackAtStrict(), osl::state::NumEffectState::findAttackNotBy(), osl::move_probability::StateInfo::findCheckmateDefender(), osl::effect_util::Pin::findLance(), osl::state::NumEffectState::findLongAttackAt(), osl::rating::PatternGroup::findMatch(), osl::move_action::EscapeFilter< P, OrigAction >::findThreat(), osl::state::NumEffectState::findThreatenedPiece(), osl::search::BreakThreatmate::generate(), osl::move_generator::OpenKingRoad< P >::generateDir(), osl::move_generator::detail::generateDir(), osl::move_generator::addeffect8::generateLongMove(), osl::move_generator::Escape< Action >::generateMovesBy(), osl::move_generator::detail::generateOpenOrCapture(), osl::state::NumEffectState::hasEffectAt(), osl::effect_util::UnblockableCheck::isMember(), osl::move_classifier::PawnDropCheckmate< P >::isMember(), osl::state::NumEffectState::makeMove(), osl::state::NumEffectState::makeUnmakeMove(), osl::rating::Pattern::match(), osl::state::SimpleState::nextPiece(), osl::rating::PatternLong::nextPieceOrEnd(), osl::threatmate::RichPredictor::predict(), osl::state::NumEffectState::prologueCapture(), osl::state::NumEffectState::prologueSimple(), and osl::state::NumEffectState::selectCheapPiece().
|
inline |
Definition at line 31 of file piece.h.
References piece.
Referenced by osl::move_generator::piece_on_board::generateLong(), osl::Move::newAddCapture(), osl::Move::newCapture(), osl::operator<(), and osl::operator==().
|
inline |
Definition at line 166 of file piece.h.
References piece.
Referenced by osl::eval::ProgressEvalGeneral< OpeningEval >::calculateAttackBonusOne(), osl::move_generator::addeffect8::canAddLongEffect(), osl::checkmate::CheckmateIfCapture::effectiveAttackCandidate0(), osl::eval::ml::EnterKingDefense::evalOne(), osl::move_generator::without_effect::generateDrop(), osl::move_generator::without_effect::generateLongMove(), osl::checkmate::King8Info::hasEffectMask(), osl::move_classifier::BlockLongEffect< P, T >::isMember(), osl::eval::ml::SilverFork::matchGold(), osl::rating::PatternLong::nextPieceOrEnd(), osl::record::csa::show(), osl::move_probability::PawnAttack::squareStatus(), and osl::effect_util::TestEffectOfMove< P, InterestEmpty, Dir >::testShort().
|
inlinestatic |
Definition at line 169 of file piece.h.
References isEmptyNum().
Referenced by osl::effect::NumSimpleEffectTable::doEffectLong(), osl::effect_util::PinOrOpen::findDirectionStep(), osl::effect_util::Pin::findDirectionStep(), osl::state::NumEffectState::makePinOpenDir(), and osl::state::NumEffectState::recalcPinOpen().
|
inline |
Definition at line 160 of file piece.h.
References piece.
Referenced by osl::checkmate::detail::blockingVerticalAttack(), osl::eval::ProgressEvalGeneral< OpeningEval >::calculateAttackBonusOne(), osl::eval::ProgressEvalGeneral< OpeningEval >::calculateEnterKingBonus(), osl::move_generator::addeffect8::canAddLongEffect(), osl::eval::ml::KnightCheck::canCheck(), osl::rating::Threatmate::captureForKnightCheck(), osl::record::KisenUtils::convertMove(), osl::eval::ml::King25EffectBoth::countEffectAndPiecesBoth(), osl::checkmate::FixedDepthSearcher2::defense(), osl::checkmate::FixedDepthSearcher::defense(), osl::checkmate::FixedDepthSearcher2::defenseEstimation(), osl::checkmate::FixedDepthSearcher::defenseEstimation(), osl::checkmate::CheckmateIfCapture::effectiveAttackCandidate0(), osl::eval::ml::King8EffectAll::effectState(), osl::eval::ml::KnightHead::eval(), osl::eval::ml::SilverFeatures::evalOne(), osl::eval::ml::King25EmptyAbs< Opening >::evalOne(), osl::eval::ml::EnterKingDefense::evalOne(), osl::eval::ml::PtypeYPawnY::evalWithUpdateBang(), osl::move_generator::addeffect8::findBlocker(), osl::search::BreakThreatmate::findBlockLong(), osl::eval::ml::BishopRookFork::findDropInLine(), osl::move_action::EscapeFilter< P, OrigAction >::findThreat(), osl::state::NumEffectState::forEachEffectOfPieceLongDir(), osl::move_generator::AdditionalLance< P >::generate(), osl::move_generator::detail::generateDir(), osl::move_generator::detail::generateDirNotKing(), osl::move_generator::promote::AllPromoteDir< P, T, noCapture, Dir >::generateIfValid(), osl::move_generator::promote::MayPromoteDir< P, T, noCapture, Dir >::generateIfValid(), osl::move_generator::piece_on_board::generateKingDir(), osl::move_generator::detail::generateKnightDir(), osl::move_generator::without_effect::generateLongMove(), osl::move_generator::piece_on_board::generatePawn(), osl::move_generator::piece_on_board::generateShort(), osl::move_generator::addeffect8::generateShortMove(), osl::move_generator::drop::generateX(), osl::checkmate::King8Info::hasEffectMask(), osl::effect_util::Neighboring8Direct::Table::hasEffectOrAdditional(), osl::checkmate::detail::hasKnightCheckmate(), osl::eval::ml::King25EffectEach< Stage >::index(), osl::state::SimpleState::isAlmostValidDrop(), osl::state::SimpleState::isConsistent(), osl::state::SimpleState::isEmptyBetween(), osl::move_classifier::TrapRook< P >::isMember(), osl::move_classifier::KingOpenMove< P >::isMemberMain(), osl::container::NearMask::make(), osl::rating::LongTarget2::match(), osl::record::csa::show(), osl::container::PieceValues::showValues(), osl::checkmate::ImmediateCheckmate::slowHasCheckmateMoveDirPiece(), osl::move_action::EscapeFilter< P, OrigAction >::suitable(), osl::eval::ml::BishopRookFork::testCenter(), osl::move_classifier::TrapRook< P >::testDirection(), osl::effect_util::TestEffectOfMove< P, InterestEmpty, Dir >::testLong(), osl::effect_util::TestEffectOfMove< P, InterestEmpty, Dir >::testShort(), osl::state::SimpleState::testValidityOtherThanEffect(), osl::search::NoCaptureStore::unknownMove(), osl::move_probability::StateInfo::updatePinnedGenerals(), osl::search::StateElements::validCaptureMove(), and osl::search::StateElements::validSimpleMove().
|
inlinestatic |
Definition at line 163 of file piece.h.
Referenced by osl::effect_util::AdditionalOrShadow::count(), osl::effect::NumSimpleEffectTable::doEffectLong(), osl::effect_util::PinOrOpen::findDirectionStep(), osl::effect_util::Pin::findDirectionStep(), osl::move_action::EscapeFilter< P, OrigAction >::findThreat(), isEdgeNum(), osl::state::NumEffectState::makePinOpenDir(), osl::state::NumEffectState::recalcPinOpen(), and osl::move_action::EscapeFilter< P, OrigAction >::suitable().
|
inline |
Definition at line 244 of file piece.h.
References osl::Square::isPieceStand(), osl::isValid(), and square().
Referenced by osl::eval::ppair::PiecePairEvalTableBase< Table >::adjustPairs(), osl::eval::ppair::PiecePairEvalTableBase< Table >::adjustPairsAfterMove(), osl::search::QuiescenceGenerator< P >::attackKnightWithPawn(), osl::eval::ProgressEvalGeneral< OpeningEval >::calculateAttackBonusOne(), osl::eval::ProgressEvalGeneral< OpeningEval >::calculateAttackRooks(), osl::eval::ProgressEvalGeneral< OpeningEval >::calculateGoldPenalty(), osl::eval::ProgressEvalGeneral< OpeningEval >::calculateRookRankBonus(), osl::eval::ProgressEvalGeneral< OpeningEval >::calculateSilverPenalty(), osl::eval::ml::SilverFeatures::canRetreat(), osl::eval::ml::GoldFeatures::canRetreat(), osl::mobility::LanceMobility::countAll(), osl::mobility::BishopMobility::countAll(), osl::mobility::BishopMobility::countAllDir(), osl::eval::ml::NumPiecesBetweenBishopAndKing::countBetween(), osl::mobility::LanceMobility::countBoth(), osl::mobility::BishopMobility::countBoth(), osl::mobility::RookMobility::countHorizontalBoth(), osl::mobility::LanceMobility::countSafe(), osl::mobility::BishopMobility::countSafe(), osl::mobility::RookMobility::countVerticalBoth(), osl::effect::EffectedNumTable::EffectedNumTable(), osl::state::SimpleState::emulateHandPiece(), osl::eval::ml::MajorY< true, ROOK >::eval(), osl::eval::ml::RookMobilityAll::eval(), osl::eval::ml::KingPieceRelative::eval(), osl::eval::ml::RookPawn< Opening >::eval(), osl::eval::ml::RookPawnY::eval(), osl::eval::ml::PtypeYY::eval(), osl::eval::ml::BishopMobilityAll::eval(), osl::eval::ml::RookEffectBase::eval(), osl::eval::ml::BishopEffectBase::eval(), osl::eval::ml::NumPiecesBetweenBishopAndKing::eval(), osl::eval::ml::BishopBishopPiece::eval(), osl::eval::ml::PawnAdvance::eval(), osl::eval::ml::SilverFeatures::eval(), osl::eval::ml::GoldFeatures::eval(), osl::eval::ml::RookRookPiece::eval(), osl::eval::ml::RookSilverKnight::eval(), osl::eval::ml::BishopSilverKnight::eval(), osl::eval::ml::AttackMajorsInBase::eval(), osl::eval::ml::KnightAdvance::eval(), osl::eval::ml::PtypeY::eval(), osl::eval::ml::PtypeX::eval(), osl::eval::ml::KnightHead::eval(), osl::eval::ml::PawnPtypeOPtypeO::eval(), osl::eval::ml::LanceEffectPieceKingRelative::eval(), osl::eval::ml::PtypeYPawnY::eval(), osl::eval::ml::MajorGoldSilverAttacked< Opening >::evalOne(), osl::eval::ml::KingRookBishop::evalOne(), osl::eval::ml::BishopExchangeSilverKing::evalOne(), osl::eval::ml::PiecePair::index(), osl::eval::ml::RookRook::index(), osl::state::NumEffectState::isConsistent(), osl::state::SimpleState::isConsistent(), osl::state::SimpleState::isOnBoard(), make1(), make2(), osl::move_probability::StateInfo::makePinOfLongPieces(), osl::annotate::ThreatmateIfMorePieces::match(), osl::state::NumEffectState::NumEffectState(), osl::eval::ml::OpenMidEndingEval::OpenMidEndingEval(), osl::eval::ml::PiecePair::pieceValueDouble(), osl::eval::ppair::PiecePairWithStand< Table >::setValues(), osl::record::myshogi::show(), show(), osl::eval::ppair::PiecePairWithStand< Table >::standBonus(), osl::move_probability::BlockLong::updateCache(), osl::eval::ml::OpenMidEndingEval::updateGoldSilverNearKing(), osl::progress::ml::NewProgress::updatePieceKingRelativeBonus(), and osl::eval::ml::PiecePair::value().
|
inlineprivate |
Definition at line 80 of file piece.h.
References piece.
Referenced by osl::eval::ml::KnightFork::accumulate(), osl::search::QuiescenceGenerator< P >::advanceBishop(), osl::search::QuiescenceGenerator< P >::attackGoldWithPawn(), osl::search::QuiescenceGenerator< P >::attackMajorPiece(), osl::search::QuiescenceGenerator< P >::attackSilverWithPawn(), osl::search::QuiescenceGenerator< P >::attackWithKnight(), osl::eval::ProgressEvalGeneral< OpeningEval >::calculateMobilityBonusBishop(), osl::eval::ProgressEvalGeneral< OpeningEval >::calculateMobilityBonusLance(), osl::eval::ProgressEvalGeneral< OpeningEval >::calculateMobilityBonusRook(), osl::eval::ProgressEvalGeneral< OpeningEval >::calculateRookRankBonus(), osl::move_generator::addeffect8::canAddLongEffect(), osl::eval::ml::KnightCheck::canCheck(), osl::move_classifier::PawnDropCheckmate< P >::canEscape(), osl::eval::ml::GoldFeatures::canRetreat(), osl::enter_king::countPiecePointsInRange(), osl::rating::ImmediateAddSupport::Test::doAction(), osl::checkmate::CheckmateIfCapture::effectiveAttackCandidate0(), osl::eval::ml::King8EffectAll::effectState(), osl::search::QuiescenceGenerator< P >::escapeAll(), osl::search::QuiescenceGenerator< P >::escapeByMoveOnly(), osl::search::QuiescenceGenerator< P >::escapeFromLastMove(), osl::eval::ml::BishopRookFork::evalOne(), osl::eval::ml::KnightFork::evalOne(), osl::effect_util::UnblockableEffect::find(), osl::move_generator::addeffect8::findBlocker(), osl::effect_util::Pin::findDirection(), osl::eval::TakeBackValue::findEffectPiecesAfterMove(), osl::effect_util::Pin::findLance(), osl::effect_util::Pin::findPtype(), osl::move_probability::StateInfo::finishUpdate(), osl::search::QuiescenceSearch2< EvalT >::generateAndExamineTakeBack2(), osl::search::MoveScore::generateCapture(), osl::search::AlphaBeta3::generateCapture(), osl::search::AlphaBeta3::generateCaptureAll(), osl::move_generator::detail::generateDir(), osl::move_generator::detail::generateDirNotKing(), osl::move_generator::detail::generateKing(), osl::move_generator::addeffect8::generateLongDrop(), osl::move_generator::addeffect8::generateLongDropWithOffset(), osl::move_generator::without_effect::generateLongMove(), osl::move_generator::detail::generateMovePiecePtypeMask(), osl::move_generator::detail::generateNotKing(), osl::move_generator::all_moves::generatePtype(), osl::move_generator::detail::generateRookLongMove(), osl::move_generator::detail::generateRookLongMoveNotKing(), osl::checkmate::King8Info::hasEffectMask(), osl::move_classifier::TrapRook< P >::isMember(), osl::move_classifier::KingOpenMove< P >::isMemberMain(), osl::checkmate::ProofNumberTable::libertyAfterAllMove(), osl::makeCapture(), osl::move_probability::BlockLong::makeLongAttackOne(), osl::eval::ml::SilverFork::matchGold(), osl::eval::ml::SilverFork::matchRook(), osl::effect_util::SendOffSquare::onlyOneSupport(), osl::search::QuiescenceGenerator< P >::promote(), osl::search::AlphaBeta3::quiesce(), osl::search::AlphaBeta3::quiesceRoot(), osl::record::ki2::show(), osl::move_classifier::TrapRook< P >::testDirection(), and osl::move_probability::StateInfo::updatePinnedGenerals().
|
inlineprivate |
|
inline |
piece がプレイヤーPの持ち物でかつボード上にある駒の場合は true.
敵の駒だったり,駒台の駒だったり,Piece::EMPTY(), PIECE_EDGEの場合は false
P(template) | - プレイヤー |
piece | - |
Definition at line 99 of file piece.h.
References isOnBoardByOwner().
Referenced by isOnBoardByOwner().
|
inline |
|
inline |
promoteしていないOnBoardの駒であることのチェック Lance位しか使い道がない?
Definition at line 151 of file piece.h.
References piece.
Referenced by osl::eval::ml::LanceMobilityAll::eval(), osl::eval::ml::RookPromoteDefense::eval(), and osl::eval::ml::BishopHead::eval().
|
inline |
Definition at line 200 of file piece.h.
References piece.
Referenced by osl::move_probability::MoveInfo::adhocAdjustAttackCheckmateDefender(), osl::move_probability::MoveInfo::adhocAdjustBreakThreatmate(), osl::move_probability::MoveInfo::adhocAdjustKeepCheckmateDefender(), osl::checkmate::OracleAdjust::attack(), osl::search::QuiescenceGenerator< P >::breakThreatmate(), osl::search::QuiescenceGenerator< P >::capture(), osl::rating::Threatmate::captureForKnightCheck(), osl::record::KisenUtils::convertMove(), osl::search::QuiescenceSearch2< EvalT >::currentValueWithLastThreat(), osl::move_action::EscapeFilter< P, OrigAction >::EscapeFilter(), osl::eval::ml::KnightHead::eval(), osl::eval::ml::PiecePair::evalWithUpdate(), osl::effect_util::AdditionalEffect::find(), osl::rating::PatternLong2::find(), osl::rating::PatternBlock::find(), osl::eval::See::findAdditionalPieces(), osl::effect_util::VirtualPin::findDirection(), osl::state::NumEffectState::findLongAttackAt(), osl::rating::PatternLongGroup2::findMatch(), osl::effect_util::Pin::findOffset(), osl::move_generator::Capture< Action >::generate1(), osl::move_generator::detail::generateOpenOrCapture(), osl::search::BreakThreatmate::generateOpenRoad(), osl::state::NumEffectState::hasEffectByPiece(), osl::state::NumEffectState::hasEffectByWithRemove(), osl::eval::ml::PiecePair::index(), osl::state::SimpleState::isConsistent(), osl::move_classifier::BlockLongEffect< P, T >::isMember(), osl::annotate::Vision3::match(), osl::move_probability::BreakThreatmate::match(), osl::move_probability::EscapeThreatened::match(), osl::effect_util::EffectUtil::FindThreat< EvalT >::operator()(), osl::operator<<(), owner(), pieceIsBlack(), osl::eval::ml::PiecePair::pieceValueDouble(), osl::effect_util::EffectUtil::safeCaptureNotByKing(), osl::search::QuiescenceSearch2< EvalT >::searchMain(), osl::ntesuki::NtesukiMoveGenerator::setOrder(), osl::record::csa::show(), osl::move_probability::PawnAttack::squareStatus(), osl::search::QuiescenceSearch2< EvalT >::staticValue(), osl::effect_util::TestEffectOfMove< P, InterestEmpty, Dir >::testLong(), and osl::move_probability::PatternCommon::updateCacheOne().
|
inlinestatic |
Definition at line 173 of file piece.h.
Referenced by osl::effect::NumSimpleEffectTable::doEffectShort(), osl::effect_util::PinOrOpen::findDirectionStep(), osl::effect_util::Pin::findDirectionStep(), osl::move_classifier::KingOpenMove< P >::isMember(), osl::state::NumEffectState::makePinOpenDir(), and osl::state::NumEffectState::recalcPinOpen().
あるpieceがPlayer pの持ち物でBASIC typeがptypeであるかどうかをチェックする. TはEMPTY, EDGEではない.
Definition at line 192 of file piece.h.
References BitOffsetPtype, osl::canPromote(), osl::isBasic(), isPlayerPtype(), piece, osl::promote(), osl::PTYPE_MAX, and osl::PTYPE_PIECE_MIN.
あるpieceがPlayer pの持ち物でPtype ptypeであるかどうかをチェックする. TはEMPTY, EDGEではない.
Definition at line 184 of file piece.h.
References BitOffsetPtype, piece, ptype(), osl::PTYPE_MAX, and osl::PTYPE_PIECE_MIN.
Referenced by osl::eval::ml::AttackMajorsInBase::addOne(), osl::eval::ml::PawnAdvanceAll::evalWithUpdateBang(), and isPlayerBasicPtype().
|
inline |
promoteした駒かどうかをチェックする
Definition at line 145 of file piece.h.
References piece.
Referenced by osl::search::QuiescenceGenerator< P >::attackWithKnight(), osl::eval::ProgressEvalGeneral< OpeningEval >::calculateMobilityBonusBishop(), osl::eval::ProgressEvalGeneral< OpeningEval >::calculateMobilityBonusLance(), osl::eval::ProgressEvalGeneral< OpeningEval >::calculateMobilityBonusRook(), osl::eval::ProgressEvalGeneral< OpeningEval >::calculateSilverPenalty(), osl::eval::ml::SilverFeatures::canRetreat(), osl::effect_action::Promote< Action >::doAction(), osl::effect_action::Promote< Action >::doActionPtype(), osl::eval::ml::RookMobilityAll::eval(), osl::eval::ml::BishopMobilityAll::eval(), osl::eval::ml::RookEffectBase::eval(), osl::eval::ml::BishopEffectBase::eval(), osl::eval::ml::PawnAdvance::eval(), osl::eval::ml::SilverFeatures::eval(), osl::eval::ml::RookSilverKnight::eval(), osl::eval::ml::BishopSilverKnight::eval(), osl::eval::ml::AttackMajorsInBase::eval(), osl::eval::ml::KnightAdvance::eval(), osl::eval::ml::KnightHead::eval(), osl::eval::ml::PawnPtypeOPtypeO::eval(), osl::eval::ml::LanceEffectPieceKingRelative::eval(), osl::move_generator::detail::generateKing(), osl::move_generator::detail::generateNotKing(), osl::move_generator::all_moves::generatePtype(), osl::move_generator::detail::generateRookLongMove(), osl::move_generator::detail::generateRookLongMoveNotKing(), osl::record::MiniBoard::getState(), osl::eval::ml::MajorY< true, ROOK >::index(), osl::eval::ml::RookPawnY::index(), osl::eval::ml::KingRookBishop::index(), osl::eval::ml::RookRook::index(), osl::eval::ml::RookPawnY::indexY(), osl::state::NumEffectState::isConsistent(), osl::state::SimpleState::isConsistent(), isPromotedNotKingGold(), osl::move_probability::PromotionBySacrifice::match(), osl::eval::ml::SilverFork::matchRook(), osl::record::MiniBoardChar50::MiniBoardChar50(), osl::state::NumEffectState::NumEffectState(), osl::eval::ml::OpenMidEndingEval::OpenMidEndingEval(), osl::move_generator::promote::EachOnBoard< Action, P, T, noCapture >::operator()(), osl::record::OPSquare::OPSquare(), promoteWithMask(), osl::move_probability::BlockLong::updateCache(), and osl::search::QuiescenceGenerator< P >::utilizePromoted().
|
inline |
Definition at line 155 of file piece.h.
References osl::GOLD, isPromoted(), osl::KING, and ptype().
Referenced by osl::effect_action::SimpleMove< Action >::doActionPtype(), osl::effect_action::BetterToPromote< Action >::doActionPtype(), osl::effect_action::AlwaysMove< Action >::doActionPtype(), osl::state::SimpleState::initPawnMask(), osl::state::SimpleState::isConsistent(), osl::effect::AddMaskAction< Liberty, P, T >::operator()(), osl::move_generator::addeffect8::ShortPieceAction< P, T, Action >::operator()(), osl::move_generator::without_effect::ShortPieceAction< P, T, Action >::operator()(), osl::move_generator::without_effect::LongPieceAction< P, T, Action, isAttackToKing >::operator()(), osl::move_generator::addeffect8::LongPieceAction< P, T, Action >::operator()(), and osl::state::SimpleState::testValidityOtherThanEffect().
|
inline |
Definition at line 177 of file piece.h.
References BitOffsetPtype, and piece.
Referenced by osl::checkmate::OracleAdjust::attack(), osl::checkmate::FixedDepthSearcher2::hasCheckmateWithGuide(), and osl::checkmate::FixedDepthSearcher::hasCheckmateWithGuide().
|
inlinestatic |
|
static |
|
inline |
Definition at line 63 of file piece.h.
References piece.
Referenced by osl::move_probability::BlockLong::addPiece(), osl::eval::See::computeValue(), osl::effect_util::AdditionalOrShadow::count(), osl::mobility::LanceMobility::countAll(), osl::mobility::BishopMobility::countAll(), osl::mobility::BishopMobility::countAllDir(), osl::eval::ml::NumPiecesBetweenBishopAndKing::countBetween(), osl::mobility::RookMobility::countHorizontalAll(), osl::mobility::RookMobility::countVerticalAll(), osl::effect::NumSimpleEffectTable::doEffect(), osl::effect::EffectedNumTable::EffectedNumTable(), osl::move_generator::Capture< Action >::escapeByCapture(), osl::eval::ml::BishopBishopPiece::eval(), osl::eval::ml::RookRookPiece::eval(), osl::eval::ml::NonPawnAttackedPtype::eval(), osl::eval::ml::LanceEffectPieceKingRelative::eval(), osl::eval::ml::KingPieceRelativeNoSupport::evalWithUpdate(), osl::eval::ml::NonPawnAttacked::evalWithUpdateBang(), osl::effect_util::VirtualPin::findDirection(), osl::effect_util::Pin::findDirection(), osl::eval::See::findEffectPiecesAfterMove(), osl::effect_util::Pin::findLance(), osl::state::NumEffectState::findLongAttackAt(), osl::effect_util::Pin::findOffset(), osl::move_action::EscapeFilter< P, OrigAction >::findThreat(), osl::state::NumEffectState::forEachEffectNotBy(), osl::move_generator::detail::generateDirNotKing(), osl::move_generator::promote::AllPromoteDir< P, T, noCapture, Dir >::generateIfValid(), osl::move_generator::promote::MayPromoteDir< P, T, noCapture, Dir >::generateIfValid(), osl::move_generator::piece_on_board::generateLance(), osl::move_generator::piece_on_board::generateLong(), osl::move_generator::addeffect8::generateLongMove(), osl::move_generator::PieceOnBoard< Action, noCapturePromote >::generatePiece(), osl::move_generator::PieceOnBoard< Action, noCapturePromote >::generatePiecePtype(), osl::move_generator::PieceOnBoard< Action, noCapturePromote >::generatePtype(), osl::move_generator::addeffect8::generateShortMove(), osl::checkmate::ImmediateCheckmate::hasCheckmateMoveDirPiece(), osl::state::NumEffectState::hasEffectByPiece(), osl::state::NumEffectState::hasEffectByWithRemove(), osl::state::NumEffectState::hasEffectNotBy(), osl::state::SimpleState::isConsistent(), make1(), makeKing(), osl::move_probability::BlockLong::makeLongAttackOne(), osl::annotate::Vision3::match(), osl::state::NumEffectState::mobilityOf(), osl::move_generator::without_effect::LongPieceAction< P, T, Action, isAttackToKing >::operator()(), osl::operator<<(), osl::state::NumEffectState::pinAttacker(), osl::state::NumEffectState::pinnedDir(), osl::state::NumEffectState::prologueCapture(), osl::state::NumEffectState::prologueSimple(), osl::state::NumEffectState::recalcPinOpen(), osl::effect_util::EffectUtil::safeCaptureNotByKing(), osl::record::csa::show(), show(), osl::container::PieceValues::showValues(), osl::checkmate::ImmediateCheckmate::slowHasCheckmateMoveDirPiece(), osl::move_action::EscapeFilter< P, OrigAction >::suitable(), osl::move_probability::PatternCommon::updateCacheOne(), osl::eval::ml::NonPawnAttackedPtype::updateChanged(), osl::eval::ml::NonPawnAttacked::updateEffectChanged(), and osl::state::NumEffectState::wasCheckEvasion().
Definition at line 71 of file piece.h.
References osl::Offset::intValue(), and piece.
|
inline |
Definition at line 210 of file piece.h.
References isPiece(), and piece.
Referenced by osl::eval::endgame::AttackDefense::addValue(), osl::search::QuiescenceGenerator< P >::attackGoldWithPawn(), osl::search::QuiescenceGenerator< P >::attackKnightWithPawn(), osl::search::QuiescenceGenerator< P >::attackSilverWithPawn(), osl::search::QuiescenceGenerator< P >::breakThreatmate(), osl::eval::ProgressEvalGeneral< OpeningEval >::calculateAttackBonusOne(), osl::eval::ProgressEvalGeneral< OpeningEval >::calculateAttackRooks(), osl::eval::ProgressEvalGeneral< OpeningEval >::calculateEnterKingBonus(), osl::eval::ProgressEvalGeneral< OpeningEval >::calculateGoldPenalty(), osl::eval::ProgressEvalGeneral< OpeningEval >::calculateRookRankBonus(), osl::eval::ProgressEvalGeneral< OpeningEval >::calculateSilverPenalty(), osl::move_classifier::PawnDropCheckmate< P >::canEscape(), osl::eval::ml::GoldFeatures::canMoveToSide(), osl::eval::ml::SilverFeatures::canRetreat(), osl::eval::ml::GoldFeatures::canRetreat(), osl::eval::ml::KnightAdvance::cantAdvance(), osl::eval::See::computeValue(), osl::record::KisenUtils::convertMove(), count(), osl::mobility::LanceMobility::countAll(), osl::mobility::BishopMobility::countAll(), osl::mobility::BishopMobility::countAllDir(), osl::eval::ml::NumPiecesBetweenBishopAndKing::countBetween(), osl::mobility::BishopMobility::countBoth(), osl::mobility::LanceMobility::countBoth(), osl::eval::ml::King25EffectBoth::countEffectAndPiecesBoth(), osl::mobility::RookMobility::countHorizontalBoth(), osl::mobility::LanceMobility::countSafe(), osl::mobility::BishopMobility::countSafe(), osl::mobility::RookMobility::countVerticalBoth(), osl::search::QuiescenceSearch2< EvalT >::currentValueWithLastThreat(), osl::effect::NumSimpleEffectTable::doBlockAt(), osl::effect::EffectedNumTable::EffectedNumTable(), osl::state::SimpleState::emulateCapture(), osl::state::SimpleState::emulateHandPiece(), osl::move_action::EscapeFilter< P, OrigAction >::EscapeFilter(), osl::eval::ml::MajorY< true, ROOK >::eval(), osl::eval::ml::RookMobilityAll::eval(), osl::eval::ml::KingPieceRelative::eval(), osl::eval::ml::RookPawn< Opening >::eval(), osl::eval::ml::RookPawnY::eval(), osl::eval::ml::BishopMobilityAll::eval(), osl::eval::ml::RookEffectBase::eval(), osl::eval::ml::RookPromoteDefense::eval(), osl::eval::ml::BishopEffectBase::eval(), osl::eval::ml::BishopHead::eval(), osl::eval::ml::NumPiecesBetweenBishopAndKing::eval(), osl::eval::ml::PawnAdvance::eval(), osl::eval::ml::BishopBishopPiece::eval(), osl::eval::ml::SilverFeatures::eval(), osl::eval::ml::RookRook::eval(), osl::eval::ml::GoldFeatures::eval(), osl::eval::ml::RookRookPiece::eval(), osl::eval::ml::RookSilverKnight::eval(), osl::eval::ml::BishopSilverKnight::eval(), osl::eval::ml::AttackMajorsInBase::eval(), osl::eval::ml::KnightAdvance::eval(), osl::eval::ml::PtypeY::eval(), osl::eval::ml::PtypeX::eval(), osl::eval::ml::KnightHead::eval(), osl::eval::ml::PawnPtypeOPtypeO::eval(), osl::eval::ml::LanceEffectPieceKingRelative::eval(), osl::eval::ml::PtypeYPawnY::eval(), osl::eval::ml::SilverAdvance26::eval(), osl::eval::ml::MajorGoldSilverAttacked< Opening >::evalOne(), osl::eval::ml::GoldFeatures::evalOne(), osl::eval::ml::BishopExchangeSilverKing::evalOne(), osl::eval::ml::EnterKingDefense::evalOne(), osl::eval::ml::KingPieceRelativeNoSupport::evalWithUpdate(), osl::eval::ml::NonPawnAttacked::evalWithUpdateBang(), osl::eval::ml::PtypeYPawnY::evalWithUpdateBang(), osl::effect_util::AdditionalEffect::find(), osl::eval::See::findAdditionalPieces(), osl::effect_util::VirtualPin::findDirection(), osl::state::NumEffectState::findLongAttackAt(), osl::rating::AttackKing8Group::findMatch(), osl::rating::PatternGroup::findMatch(), osl::rating::PatternLongGroup2::findMatch(), osl::effect_util::Pin::findOffset(), osl::move_action::EscapeFilter< P, OrigAction >::findThreat(), osl::state::SimpleState::flipHorizontal(), osl::move_generator::Escape< Action >::generate(), osl::move_generator::OpenKingRoad< P >::generateDir(), osl::move_generator::Escape< Action >::generateEscape(), osl::search::BreakThreatmate::generateOpenRoad(), osl::search::BigramKillerMove::getMove(), osl::state::NumEffectState::hasEffectByWithRemove(), osl::state::NumEffectState::hasEffectNotBy(), osl::eval::ml::MajorY< true, ROOK >::index(), osl::eval::ml::Pin::index(), osl::eval::ml::KingPieceRelative::index(), osl::eval::ml::RookPawnY::index(), osl::eval::ml::MajorGoldSilverAttacked< Opening >::index(), osl::eval::ml::KingRookBishop::index(), osl::eval::ml::PtypeY::index(), osl::eval::ml::PtypeX::index(), osl::eval::ml::King25EffectEach< Stage >::index(), osl::eval::ml::NonPawnAttackedPtypePair::index1(), osl::eval::ml::NonPawnAttacked::indexK(), osl::eval::ml::PawnDropBoth::indexX(), osl::eval::ml::King8Effect::indexY(), osl::eval::ml::PawnDropBoth::indexY(), osl::eval::ml::RookPawnY::indexY(), osl::state::SimpleState::initPawnMask(), osl::state::SimpleState::isConsistent(), osl::move_classifier::BlockLongEffect< P, T >::isMember(), make1(), make2(), osl::move_probability::BlockLong::makeLongAttackOne(), osl::rating::AttackKing8::match(), osl::rating::Pattern::match(), osl::rating::LongTarget2::match(), osl::rating::RookDefense::match(), osl::move_probability::AttackToOpposingSliders::match(), osl::move_probability::LureDefender::match(), osl::eval::ml::SilverFork::matchGold(), osl::eval::ml::SilverFork::matchRook(), osl::record::MiniBoardChar50::MiniBoardChar50(), osl::eval::MinorPieceBonus::MinorPieceBonus(), osl::state::NumEffectState::NumEffectState(), osl::eval::ml::OpenMidEndingEval::OpenMidEndingEval(), osl::effect_util::EffectUtil::FindThreat< EvalT >::operator()(), osl::operator<<(), osl::record::OPiece::OPiece(), osl::record::OSquare::OSquare(), osl::state::NumEffectState::pinAttacker(), osl::state::NumEffectState::pinnedCanMoveTo(), osl::state::NumEffectState::pinnedDir(), osl::threatmate::RichPredictor::predict(), osl::state::SimpleState::rotate180(), osl::effect_util::EffectUtil::safeCaptureNotByKing(), osl::search::QuiescenceSearch2< EvalT >::searchMain(), osl::ntesuki::NtesukiMoveGenerator::setOrder(), osl::eval::ppair::PiecePairWithStand< Table >::setValues(), osl::record::myshogi::show(), osl::record::csa::show(), show(), osl::container::PieceValues::showValues(), osl::move_probability::PawnAttack::squareStatus(), osl::search::QuiescenceSearch2< EvalT >::staticValueWithThreat(), osl::eval::See::FindEffectMore::store(), osl::annotate::ThreatmateIfMorePieces::suitable(), osl::state::SimpleState::testValidityOtherThanEffect(), osl::move_probability::BlockLong::updateCache(), osl::move_probability::PatternCommon::updateCacheOne(), osl::eval::ml::OpenMidEndingEval::updateGoldSilverNearKing(), osl::eval::endgame::AttackDefense::updateKingMove(), osl::progress::ml::NewProgress::updatePieceKingRelativeBonus(), osl::eval::endgame::DefenseKing::valueOf(), osl::eval::endgame::AttackKing::valueOf(), osl::eval::endgame::AttackDefense::valueOf(), and osl::state::NumEffectState::wasCheckEvasion().
|
inline |
pieceであることが分かっている時に,更にBlackかどうかをチェックする.
Definition at line 206 of file piece.h.
References isPiece(), and piece.
Referenced by osl::eval::ml::LanceMobilityAll::eval(), and osl::move_generator::detail::generateOpenOrCapture().
|
inline |
|
inline |
Definition at line 132 of file piece.h.
References BitOffsetMovePromote, BitOffsetPromote, isPromoted(), piece, and Piece().
Referenced by osl::effect::ApplyDoUndoCaptureMove< P, SignatureEffect< BaseState > >::doUndoCaptureMove(), osl::effect::ApplyDoUndoSimpleMove< P, SignatureEffect< BaseState > >::doUndoSimpleMove(), osl::state::NumEffectState::prologueCapture(), and osl::state::NumEffectState::prologueSimple().
|
inline |
Definition at line 56 of file piece.h.
References BitOffsetPtype, and piece.
Referenced by osl::eval::ml::KnightFork::accumulate(), osl::eval::ml::PiecePairKing::add(), osl::eval::ml::MajorCheckWithCapture::addOne(), osl::eval::ml::PiecePairKing::addSub(), osl::eval::endgame::AttackDefense::addValue(), osl::move_probability::MoveInfo::adhocAdjustBishopFork(), osl::search::QuiescenceGenerator< P >::advanceBishop(), osl::checkmate::OracleAdjust::attack(), osl::search::QuiescenceGenerator< P >::attackGoldWithPawn(), osl::search::QuiescenceGenerator< P >::attackKnightWithPawn(), osl::search::QuiescenceGenerator< P >::attackMajorPiece(), osl::search::QuiescenceGenerator< P >::attackSilverWithPawn(), osl::search::QuiescenceGenerator< P >::attackWithKnight(), osl::eval::ProgressEvalGeneral< OpeningEval >::calculateRookRankBonus(), osl::search::QuiescenceGenerator< P >::capture(), osl::record::KisenUtils::convertMove(), count(), osl::mobility::LanceMobility::countAll(), osl::mobility::BishopMobility::countAll(), osl::mobility::BishopMobility::countAllDir(), osl::mobility::LanceMobility::countBoth(), osl::mobility::BishopMobility::countBoth(), osl::mobility::RookMobility::countHorizontalBoth(), osl::enter_king::countPiecePointsInRange(), osl::mobility::LanceMobility::countSafe(), osl::mobility::BishopMobility::countSafe(), osl::mobility::RookMobility::countVerticalBoth(), osl::effect_action::SimpleBetterToPromote< Action >::doAction(), osl::effect_action::Promote< Action >::doAction(), osl::effect_action::SimpleMove< Action >::doAction(), osl::effect_action::BetterToPromote< Action >::doAction(), osl::effect_action::AlwaysMove< Action >::doAction(), osl::effect_util::EffectUtil::SafeCapture::doAction(), osl::effect_action::SimpleBetterToPromote< Action >::doActionPtype(), osl::effect_action::SimpleMove< Action >::doActionPtype(), osl::effect_action::BetterToPromote< Action >::doActionPtype(), osl::effect_action::AlwaysMove< Action >::doActionPtype(), osl::effect::NumSimpleEffectTable::doBlockAt(), osl::state::NumEffectState::doCaptureMove(), osl::state::NumEffectState::doUndoCaptureMove(), osl::effect::EffectedNumTable::EffectedNumTable(), osl::state::SimpleState::emulateCapture(), osl::state::SimpleState::emulateHandPiece(), osl::search::QuiescenceGenerator< P >::escapeAll(), osl::move_action::EscapeFilter< P, OrigAction >::EscapeFilter(), osl::search::QuiescenceGenerator< P >::escapeNormalPiece(), osl::eval::ml::SimplePin::eval(), osl::eval::ml::Pin::eval(), osl::eval::ml::KingPieceRelative::eval(), osl::eval::ml::RookPromoteDefense::eval(), osl::eval::ml::BishopBishopPiece::eval(), osl::eval::ml::RookRookPiece::eval(), osl::eval::ml::PtypeY::eval(), osl::eval::ml::PtypeX::eval(), osl::eval::ml::KnightHead::eval(), osl::eval::ml::NonPawnAttackedPtype::eval(), osl::eval::ml::PtypeYPawnY::eval(), osl::eval::ml::SilverAdvance26::eval(), osl::eval::ml::PinPtypeAll::evalOne(), osl::eval::ml::CheckShadowPtype::evalOne(), osl::eval::ml::EnterKingDefense::evalOne(), osl::eval::ml::BishopRookFork::evalOne(), osl::eval::ml::KnightFork::evalOne(), osl::eval::ml::NonPawnAttackedPtype::evalWithUpdateBang(), osl::eval::ml::PtypeYPawnY::evalWithUpdateBang(), osl::eval::endgame::AttackDefense::expect(), osl::rating::PatternBlock::find(), osl::effect_util::VirtualPin::findDirection(), osl::effect_util::Pin::findDirection(), osl::eval::TakeBackValue::findEffectPiecesAfterMove(), osl::rating::AttackKing8Group::findMatch(), osl::rating::PatternGroup::findMatch(), osl::rating::PatternLongGroup2::findMatch(), osl::state::SimpleState::flipHorizontal(), osl::move_generator::PieceOnBoard< Action, noCapturePromote >::generate(), osl::move_generator::detail::generateDirNotKing(), osl::move_generator::Escape< Action >::generateEscape(), osl::move_generator::detail::generateMovePiecePtypeMask(), osl::move_generator::Escape< Action >::generateMoves(), osl::move_generator::PieceOnBoard< Action, noCapturePromote >::generatePiece(), osl::move_generator::PieceOnBoard< Action, noCapturePromote >::generatePiecePtypeUnsafe(), osl::move_generator::PieceOnBoard< Action, noCapturePromote >::generatePieceUnsafe(), osl::move_generator::piece_on_board::generatePtypePromote(), osl::search::BigramKillerMove::getMove(), osl::checkmate::ImmediateCheckmate::hasCheckmateMoveDirPiece(), osl::checkmate::detail::hasKnightCheckmate(), osl::rating::PinAttack::index(), osl::eval::ml::KingPieceRelativeNoSupport::index(), osl::eval::ml::MajorGoldSilverAttacked< Opening >::index(), osl::rating::ImmediateAddSupport::index(), osl::eval::ml::PtypeY::index(), osl::eval::ml::PtypeX::index(), osl::eval::ml::NonPawnAttackedPtypePair::index1(), osl::eval::ml::NonPawnAttacked::indexK(), osl::progress::ml::NewProgress::indexRelative(), osl::state::SimpleState::isConsistent(), osl::move_classifier::BlockLongEffect< P, T >::isMember(), isPlayerPtype(), isPromotedNotKingGold(), osl::checkmate::ProofNumberTable::libertyAfterAllMove(), make1(), make2(), osl::move_probability::StateInfo::makePinOfLongPieces(), osl::rating::PinAttack::match(), osl::rating::AttackKing8::match(), osl::rating::Pattern::match(), osl::annotate::ThreatmateIfMorePieces::match(), osl::rating::LongTarget2::match(), osl::move_probability::AttackFromOpposingSliders::match(), osl::move_probability::AttackToOpposingSliders::match(), osl::move_probability::BreakThreatmate::match(), osl::move_probability::LureDefender::match(), osl::move_probability::AttackKing8Long::match(), osl::move_probability::CoverFork::match(), osl::move_probability::PromotionBySacrifice::match(), osl::move_probability::EscapeThreatened::match(), osl::eval::ml::SilverFork::matchGold(), osl::eval::ml::SilverFork::matchRook(), osl::record::MiniBoardChar50::MiniBoardChar50(), osl::eval::ml::OpenMidEndingEval::OpenMidEndingEval(), osl::PieceBasicLessThan::operator()(), osl::effect::AddMaskAction< Liberty, P, T >::operator()(), osl::operator<<(), osl::record::OPiece::OPiece(), osl::search::QuiescenceGenerator< P >::promote(), promote(), osl::state::SimpleState::rotate180(), osl::effect_util::EffectUtil::safeCaptureNotByKing(), osl::ntesuki::NtesukiMoveGenerator::setOrder(), osl::eval::ppair::PiecePairWithStand< Table >::setValues(), osl::record::myshogi::show(), osl::record::csa::show(), osl::record::ki2::show(), show(), osl::container::PieceValues::showValues(), osl::checkmate::ImmediateCheckmate::slowHasCheckmateMoveDirPiece(), osl::move_probability::PawnAttack::squareStatus(), osl::search::QuiescenceSearch2< EvalT >::staticValueWithThreat(), osl::eval::ml::PiecePairKing::sub(), osl::move_action::EscapeFilter< P, OrigAction >::suitable(), osl::move_probability::ToEffect::supportAttack(), osl::state::SimpleState::testValidityOtherThanEffect(), osl::move_action::NoAddEffectFilter< OrigAction >::unknownMove(), osl::move_action::NoEffectFilter< P, OrigAction >::unknownMove(), osl::move_action::Store::unknownMove(), osl::search::Store::unknownMove(), osl::move_action::NotKingOpenFilter< P, OrigAction >::unknownMove(), osl::move_action::ToAroundKing8Filter< P, OrigAction >::unknownMove(), osl::search::NoCaptureStore::unknownMove(), osl::move_action::ToAroundKing24Filter< P, OrigAction >::unknownMove(), osl::move_action::unknownMove(), osl::eval::ml::NonPawnAttackedPtype::updateChanged(), osl::eval::endgame::AttackDefense::updateKingMove(), osl::progress::ml::NewProgress::updatePieceKingRelativeBonus(), osl::move_probability::StateInfo::updatePinnedGenerals(), osl::search::QuiescenceGenerator< P >::utilizePromoted(), osl::eval::endgame::DefenseKing::valueOf(), and osl::eval::endgame::AttackKing::valueOf().
|
inline |
Definition at line 59 of file piece.h.
References BitOffsetPtype, and piece.
Referenced by osl::checkmate::DualDfpn::OraclePool::addKey(), osl::move_probability::MoveInfo::adhocAdjustBreakThreatmate(), osl::eval::ml::PiecePair::adjust12One(), osl::search::QuiescenceGenerator< P >::attackMajorPieceFirstSelection(), osl::search::QuiescenceGenerator< P >::attackSilverWithPawn(), osl::search::QuiescenceGenerator< P >::attackToPinned(), osl::move_generator::addeffect8::canAddLongEffect(), osl::eval::ml::PawnAdvanceUtil::cantAdvance(), osl::search::QuiescenceGenerator< P >::check(), osl::search::QuiescenceSearch2< EvalT >::currentValueWithLastThreat(), osl::checkmate::FixedDepthSearcher2::defenseEstimation(), osl::checkmate::FixedDepthSearcher::defenseEstimation(), osl::eval::ppair::PiecePairWithStand< PiecePairPieceTable >::diffAfterCaptureMove(), osl::eval::ppair::PiecePairEvalTableBase< PiecePairPieceTable >::diffAfterCaptureMove(), osl::eval::ppair::PiecePairWithStand< PiecePairPieceTable >::diffAfterSimpleMove(), osl::eval::ppair::PiecePairEvalTableBase< PiecePairPieceTable >::diffAfterSimpleMove(), osl::effect::NumSimpleEffectTable::doEffect(), osl::effect::ApplyDoUndoCaptureMove< P, SignatureEffect< BaseState > >::doUndoCaptureMove(), osl::effect::ApplyDoUndoSimpleMove< P, SignatureEffect< BaseState > >::doUndoSimpleMove(), osl::checkmate::CheckmateIfCapture::effectiveAttackCandidate0(), osl::eval::ml::PieceEval::eval(), osl::eval::endgame::AttackDefense::expect(), osl::effect_util::AdditionalEffect::find(), osl::effect_util::UnblockableEffect::find(), osl::eval::See::findAdditionalPieces(), osl::move_generator::addeffect8::findBlocker(), osl::state::NumEffectState::forEachEffectOfPiece(), osl::move_generator::addeffect8::generateLongDropWithOffset(), osl::hash::HashKey::HashKey(), osl::eval::ml::PiecePair::index(), osl::eval::ml::PtypeYY::index(), osl::eval::ml::King25EffectEachBoth::index(), osl::eval::ppair::PiecePairIndex::indexOf(), osl::state::SimpleState::isAlmostValidMove(), osl::move_probability::BreakThreatmate::isDefendingKing8(), osl::effect_util::UnblockableCheck::isMember(), osl::move_classifier::TrapRook< P >::isMember(), osl::move_classifier::KingOpenMove< P >::isMemberMain(), osl::checkmate::ProofNumberTable::libertyAfterAllMove(), osl::move_probability::BlockLong::makeLongAttackOne(), osl::move_probability::BreakThreatmate::match(), osl::move_probability::PromotionBySacrifice::match(), osl::eval::ml::OpenMidEndingEval::OpenMidEndingEval(), osl::PiecePtypeMoreThan::operator()(), osl::effect_util::EffectUtil::FindThreat< EvalT >::operator()(), osl::state::operator==(), osl::eval::ppair::PiecePairWithStand< Table >::PiecePairWithStand(), osl::record::KanjiPrint::print(), osl::state::NumEffectState::prologueCapture(), osl::state::NumEffectState::prologueDrop(), osl::state::NumEffectState::prologueSimple(), osl::eval::ppair::PiecePairWithStand< Table >::setValues(), osl::record::usi::show(), osl::eval::ppair::PiecePairWithStand< Table >::standBonus(), osl::search::QuiescenceSearch2< EvalT >::staticValue(), osl::eval::See::FindEffectMore::store(), osl::effect_action::StorePtypeOSquare::store(), osl::annotate::ThreatmateIfMorePieces::suitable(), osl::eval::ml::PiecePair::sum12One(), osl::move_probability::PatternCommon::updateCacheOne(), osl::move_probability::StateInfo::updatePinnedGenerals(), osl::eval::ml::PiecePair::value(), osl::eval::ml::PiecePair::valueCompiled(), osl::eval::endgame::DefenseKing::valueOf(), osl::eval::endgame::AttackKing::valueOf(), and osl::eval::endgame::AttackDefense::valueOf().
|
inline |
Definition at line 76 of file piece.h.
References piece, and osl::Square::uintValue().
|
inline |
Definition at line 67 of file piece.h.
References osl::Square::makeDirect(), and piece.
Referenced by osl::eval::ml::PiecePairKing::add(), osl::eval::ml::MajorCheckWithCapture::addOne(), osl::eval::ml::AttackMajorsInBase::addOne(), osl::move_probability::BlockLong::addPiece(), osl::eval::ml::PiecePairKing::addSub(), osl::move_probability::MoveInfo::adhocAdjustKeepCheckmateDefender(), osl::move_probability::MoveInfo::adhocAdjustSlider(), osl::search::QuiescenceGenerator< P >::advanceBishop(), osl::checkmate::OracleAdjust::attack(), osl::search::QuiescenceGenerator< P >::attackGoldWithPawn(), osl::search::QuiescenceGenerator< P >::attackKnightWithPawn(), osl::search::QuiescenceGenerator< P >::attackMajorPiece(), osl::search::QuiescenceGenerator< P >::attackSilverWithPawn(), osl::search::QuiescenceGenerator< P >::attackWithKnight(), osl::search::QuiescenceGenerator< P >::breakThreatmate(), osl::eval::ProgressEvalGeneral< OpeningEval >::calculateAttackRooks(), osl::eval::ProgressEvalGeneral< OpeningEval >::calculateGoldPenalty(), osl::eval::ProgressEvalGeneral< OpeningEval >::calculateRookRankBonus(), osl::eval::ProgressEvalGeneral< OpeningEval >::calculateSilverPenalty(), osl::move_classifier::PawnDropCheckmate< P >::canEscape(), osl::eval::ml::GoldFeatures::canMoveToSide(), osl::eval::ml::SilverFeatures::canRetreat(), osl::eval::ml::GoldFeatures::canRetreat(), osl::eval::ml::KnightAdvance::cantAdvance(), osl::eval::ml::PawnAdvanceUtil::cantAdvance(), osl::search::QuiescenceGenerator< P >::capture(), osl::eval::See::computeValue(), osl::effect_util::AdditionalOrShadow::count(), osl::mobility::LanceMobility::countAll(), osl::mobility::BishopMobility::countAllDir(), osl::eval::ml::NumPiecesBetweenBishopAndKing::countBetween(), osl::mobility::LanceMobility::countBoth(), osl::mobility::BishopMobility::countBoth(), osl::mobility::RookMobility::countHorizontalBoth(), osl::mobility::RookMobility::countHorizontalSafe(), osl::mobility::LanceMobility::countSafe(), osl::mobility::BishopMobility::countSafe(), osl::mobility::RookMobility::countVerticalBoth(), osl::mobility::RookMobility::countVerticalSafe(), osl::search::QuiescenceSearch2< EvalT >::currentValueWithLastThreat(), osl::move_probability::CoverFork::defending(), osl::checkmate::FixedDepthSearcher2::defense(), osl::checkmate::FixedDepthSearcher::defense(), osl::checkmate::FixedDepthSearcher2::defenseEstimation(), osl::checkmate::FixedDepthSearcher::defenseEstimation(), osl::effect_action::SimpleBetterToPromote< Action >::doAction(), osl::effect_action::Promote< Action >::doAction(), osl::move_action::CaptureFrom< P, OrigAction >::doAction(), osl::effect_action::SimpleMove< Action >::doAction(), osl::effect_action::BetterToPromote< Action >::doAction(), osl::effect_action::AlwaysMove< Action >::doAction(), osl::effect_util::EffectUtil::SafeCapture::doAction(), osl::effect_action::SimpleBetterToPromote< Action >::doActionPtype(), osl::effect_action::SimpleMove< Action >::doActionPtype(), osl::effect_action::Promote< Action >::doActionPtype(), osl::effect_action::BetterToPromote< Action >::doActionPtype(), osl::effect_action::AlwaysMove< Action >::doActionPtype(), osl::effect::NumSimpleEffectTable::doBlockAt(), osl::effect::NumSimpleEffectTable::doEffect(), osl::effect::EffectedNumTable::EffectedNumTable(), osl::checkmate::CheckmateIfCapture::effectiveAttackCandidate0(), osl::state::SimpleState::emulateCapture(), osl::state::SimpleState::emulateHandPiece(), osl::search::QuiescenceGenerator< P >::escapeAll(), osl::search::QuiescenceGenerator< P >::escapeNormalPiece(), osl::eval::ml::RookMobilityAll::eval(), osl::eval::ml::KingPieceRelative::eval(), osl::eval::ml::RookPawn< Opening >::eval(), osl::eval::ml::RookPawnY::eval(), osl::eval::ml::LanceMobilityAll::eval(), osl::eval::ml::RookEffectBase::eval(), osl::eval::ml::RookPromoteDefense::eval(), osl::eval::ml::BishopEffectBase::eval(), osl::eval::ml::BishopHead::eval(), osl::eval::ml::BishopBishopPiece::eval(), osl::eval::ml::PawnAdvance::eval(), osl::eval::ml::RookRookPiece::eval(), osl::eval::ml::RookSilverKnight::eval(), osl::eval::ml::BishopSilverKnight::eval(), osl::eval::ml::KnightAdvance::eval(), osl::eval::ml::PtypeY::eval(), osl::eval::ml::PtypeX::eval(), osl::eval::ml::KnightHead::eval(), osl::eval::ml::PawnPtypeOPtypeO::eval(), osl::eval::ml::NonPawnAttackedPtype::eval(), osl::eval::ml::PtypeYPawnY::eval(), osl::eval::ml::PiecePairKing::evalOne(), osl::eval::ml::PinPtypeAll::evalOne(), osl::eval::ml::MajorGoldSilverAttacked< Opening >::evalOne(), osl::eval::ml::CheckShadowPtype::evalOne(), osl::eval::ml::SilverFeatures::evalOne(), osl::eval::ml::King25EmptySquareNoEffect::evalOne(), osl::eval::ml::GoldFeatures::evalOne(), osl::eval::ml::PromotedMinorPieces::evalOne(), osl::eval::ml::King25Effect3::evalOne(), osl::eval::ml::BishopExchangeSilverKing::evalOne(), osl::eval::ml::BishopRookFork::evalOne(), osl::eval::ml::KnightFork::evalOne(), osl::eval::ml::PiecePair::evalWithUpdate(), osl::eval::ml::PawnAdvanceAll::evalWithUpdateBang(), osl::search::QuiescenceSearch2< EvalT >::examineCapture(), osl::effect_util::AdditionalEffect::find(), osl::rating::PatternLong2::find(), osl::rating::PatternBlock::find(), osl::eval::See::findAdditionalPieces(), osl::move_generator::addeffect8::findBlocker(), osl::effect_util::VirtualPin::findDirection(), osl::effect_util::Pin::findDirection(), osl::eval::See::findEffectPiecesAfterMove(), osl::effect_util::Pin::findPtype(), osl::move_action::EscapeFilter< P, OrigAction >::findThreat(), osl::state::SimpleState::flipHorizontal(), osl::state::NumEffectState::forEachEffectOfPiece(), osl::search::BreakThreatmate::generate(), osl::move_generator::Escape< Action >::generate(), osl::search::QuiescenceSearch2< EvalT >::generateAndExamineTakeBack2(), osl::move_generator::detail::generateBishopLongMove(), osl::move_generator::detail::generateBishopLongMoveNotKing(), osl::move_generator::Escape< Action >::generateBlockingKing(), osl::checkmate::FixedDepthSearcher::generateBlockingWhenLiberty0(), osl::checkmate::FixedDepthSearcher2::generateBlockingWhenLiberty0(), osl::search::MoveScore::generateCapture(), osl::search::AlphaBeta3::generateCapture(), osl::search::AlphaBeta3::generateCaptureAll(), osl::move_generator::detail::generateDir(), osl::move_generator::detail::generateDirNotKing(), osl::move_generator::Escape< Action >::generateEscape(), osl::move_generator::promote::AllPromoteDir< P, T, noCapture, Dir >::generateIfValid(), osl::move_generator::promote::MayPromoteDir< P, T, noCapture, Dir >::generateIfValid(), osl::search::MoveGenerator::generateKingEscape(), osl::move_generator::detail::generateKnightDir(), osl::move_generator::addeffect8::generateLongMove(), osl::move_generator::detail::generateMovePiecePtypeMask(), osl::move_generator::Escape< Action >::generateMovesBy(), osl::move_generator::detail::generateMoveToPtypeMaskWithPieceMask(), osl::move_generator::detail::generateOpenOrCapture(), osl::move_generator::piece_on_board::generatePawn(), osl::move_generator::PieceOnBoard< Action, noCapturePromote >::generatePiece(), osl::move_generator::PieceOnBoard< Action, noCapturePromote >::generatePiecePtype(), osl::move_generator::PieceOnBoard< Action, noCapturePromote >::generatePiecePtypeUnsafe(), osl::move_generator::PieceOnBoard< Action, noCapturePromote >::generatePieceUnsafe(), osl::move_generator::PieceOnBoard< Action, noCapturePromote >::generatePtypeUnsafe(), osl::move_generator::detail::generateRookLongMove(), osl::move_generator::detail::generateRookLongMoveNotKing(), osl::move_generator::addeffect8::generateShortMove(), osl::search::BigramKillerMove::getMove(), osl::checkmate::ImmediateCheckmate::hasCheckmateMoveDirPiece(), osl::state::NumEffectState::hasEffectInDirection(), osl::effect_util::Pin::hasEffectWithOffset(), osl::hash::HashKey::HashKey(), osl::checkmate::detail::hasKnightCheckmate(), osl::eval::ml::MajorY< true, ROOK >::index(), osl::eval::ml::Pin::index(), osl::rating::PinAttack::index(), osl::eval::ml::PiecePair::index(), osl::eval::ml::KingPieceRelative::index(), osl::eval::ml::KingPieceRelativeNoSupport::index(), osl::eval::ml::RookPawnY::index(), osl::eval::ml::PtypeYY::index(), osl::rating::ImmediateAddSupport::index(), osl::eval::ml::KingRookBishop::index(), osl::eval::ml::RookRook::index(), osl::eval::ml::PtypeY::index(), osl::eval::ml::PtypeX::index(), osl::eval::ml::NonPawnAttackedPtypePair::index1(), osl::eval::ml::NonPawnAttacked::indexK(), osl::eval::ppair::PiecePairIndex::indexOf(), osl::progress::ml::NewProgress::indexRelative(), osl::eval::ml::PawnDropBoth::indexX(), osl::eval::ml::King8Effect::indexY(), osl::eval::ml::PawnDropBoth::indexY(), osl::eval::ml::RookPawnY::indexY(), osl::state::SimpleState::initPawnMask(), osl::state::NumEffectState::isConsistent(), osl::state::SimpleState::isConsistent(), osl::move_probability::BreakThreatmate::isDefendingKing8(), osl::effect_util::UnblockableCheck::isMember(), osl::move_classifier::PawnDropCheckmate< P >::isMember(), osl::move_classifier::BlockLongEffect< P, T >::isMember(), isOnBoard(), osl::checkmate::ProofNumberTable::libertyAfterAllMove(), osl::checkmate::King8Info::make(), osl::makeCapture(), osl::move_probability::BlockLong::makeLongAttackOne(), osl::move_probability::StateInfo::makePinOfLongPieces(), osl::rating::PinAttack::match(), osl::rating::RookDefense::match(), osl::move_probability::AttackToOpposingSliders::match(), osl::move_probability::LongRecapture::match(), osl::move_probability::BreakThreatmate::match(), osl::move_probability::LureDefender::match(), osl::move_probability::AttackKing8Long::match(), osl::move_probability::CoverFork::match(), osl::move_probability::PromotionBySacrifice::match(), osl::move_probability::EscapeThreatened::match(), osl::eval::ml::SilverFork::matchGold(), osl::eval::ml::SilverFork::matchRook(), osl::record::MiniBoardChar50::MiniBoardChar50(), osl::state::NumEffectState::NumEffectState(), osl::eval::ml::OpenMidEndingEval::OpenMidEndingEval(), osl::effect::AddMaskAction< Liberty, P, T >::operator()(), osl::ntesuki::CaptureHelper< P >::operator()(), osl::move_generator::promote::EachOnBoard< Action, P, T, noCapture >::operator()(), osl::move_generator::without_effect::GoldKingAction< P, T, Action >::operator()(), osl::move_generator::without_effect::ShortPieceAction< P, T, Action >::operator()(), osl::move_generator::without_effect::LongPieceAction< P, T, Action, isAttackToKing >::operator()(), osl::operator<<(), osl::record::OPiece::OPiece(), osl::record::OSquare::OSquare(), osl::eval::ml::PinPtypeAll::pawnAttack(), osl::eval::ml::PiecePair::pieceValueDouble(), osl::state::NumEffectState::pinnedCanMoveTo(), osl::state::NumEffectState::pinnedDir(), osl::search::QuiescenceGenerator< P >::promote(), osl::search::AlphaBeta3::quiesce(), osl::search::AlphaBeta3::quiesceRoot(), osl::state::SimpleState::rotate180(), osl::search::QuiescenceSearch2< EvalT >::searchMain(), osl::record::myshogi::show(), osl::record::ki2::show(), show(), osl::container::PieceValues::showValues(), osl::checkmate::ImmediateCheckmate::slowHasCheckmateMoveDirPiece(), osl::search::QuiescenceSearch2< EvalT >::staticValueWithThreat(), osl::eval::See::FindEffectMore::store(), osl::effect_action::StorePtypeOSquare::store(), osl::eval::ml::PiecePairKing::sub(), osl::move_action::EscapeFilter< P, OrigAction >::suitable(), osl::annotate::ThreatmateIfMorePieces::suitable(), osl::search::QuiescenceSearch2< EvalT >::takeBackValue(), osl::eval::ml::NonPawnAttackedPtype::updateChanged(), osl::eval::ml::OpenMidEndingEval::updateGoldSilverNearKing(), osl::progress::ml::NewProgress::updatePawnFacing(), osl::move_probability::StateInfo::updatePinnedGenerals(), osl::search::QuiescenceGenerator< P >::utilizePromoted(), osl::eval::ml::PiecePair::value(), osl::eval::ml::PiecePair::valueCompiled(), osl::eval::endgame::DefenseKing::valueOf(), osl::eval::endgame::AttackKing::valueOf(), and osl::eval::endgame::AttackDefense::valueOf().
|
inline |
|
static |
Definition at line 36 of file piece.h.
Referenced by promoteWithMask().
|
static |
Definition at line 35 of file piece.h.
Referenced by promoteWithMask().
|
static |
Definition at line 34 of file piece.h.
Referenced by isPlayerBasicPtype(), isPlayerPtype(), isPtype(), osl::Move::newCapture(), ptype(), and ptypeO().
|
private |
Definition at line 24 of file piece.h.
Referenced by canMoveOn(), captured(), checkPromote(), intValue(), isEdge(), isEmpty(), isOnBoardByOwner(), isOnBoardNotPromoted(), isPiece(), isPlayerBasicPtype(), isPlayerPtype(), isPromoted(), isPtype(), number(), operator+=(), owner(), pieceIsBlack(), promote(), promoteWithMask(), ptype(), ptypeO(), setSquare(), square(), and unpromote().
|
static |
Definition at line 29 of file piece.h.
Referenced by count(), osl::eval::ml::PiecePair::eval(), osl::eval::ml::KingPieceRelative::eval(), osl::eval::ml::PtypeYY::eval(), osl::eval::ml::PtypeY::eval(), osl::eval::ml::PtypeX::eval(), osl::eval::ml::PtypeYPawnY::eval(), osl::search::MoveScore::generateCapture(), osl::state::NumEffectState::isConsistent(), make1(), make2(), osl::eval::ml::OpenMidEndingEval::OpenMidEndingEval(), osl::search::MoveMarker::pieceIndex(), osl::eval::ppair::PiecePairWithStand< Table >::PiecePairWithStand(), osl::progress::ml::NewProgress::setUp(), osl::state::NumEffectState::showEffect(), and osl::progress::ml::NewProgress::updatePieceKingRelativeBonus().