Static Public Member Functions | |
template<Player P> | |
static void | findEffectPieces (const NumEffectState &state, Square effect_to, PtypeOSquareVector &my_pieces, PtypeOSquareVector &op_pieces) |
effectTo に利きのある駒を全て集める More... | |
template<Player P> | |
static void | findEffectPiecesAfterMove (const NumEffectState &state, Move move, PtypeOSquareVector &my_pieces, PtypeOSquareVector &op_pieces) |
move 後に move.to() に利きのある駒を全て集める More... | |
template<Player P> | |
static int | computeValue (Square target, PtypeO ptypeO, const PtypeOSquareVector &my_pieces, const PtypeOSquareVector &op_pieces) |
PtypeOSquareVector をもとに取り返し値を計算する More... | |
Definition at line 61 of file pieceEval.tcc.
|
inlinestatic |
PtypeOSquareVector をもとに取り返し値を計算する
FIXME: 利きを延ばすコードを入れる前に PtypeOSquareVector を PtypeO,Square のベクタに変更する必要がある. computeDiffAfterMoveMulti などで駒を動かさずに, move 後の取り合いを考えている時に,piece.square() が必ずしも 取り合いのためのposition ではないため.
P | alt(P) からの取り返し |
target | ここに関する取り返し |
ptypeo | target にあると想定される駒 |
Definition at line 146 of file pieceEval.tcc.
References osl::canPromote(), osl::Square::canPromote(), osl::eval::PtypeEvalTable::captureValue(), osl::eval::max(), osl::promote(), osl::eval::PtypeEvalTable::promoteValue(), and osl::eval::Ptype_Eval_Table.
|
inlinestatic |
effectTo に利きのある駒を全て集める
Definition at line 65 of file pieceEval.tcc.
|
inlinestatic |
move 後に move.to() に利きのある駒を全て集める
この部分は effectの種類によっては高速に求まるかもしれない
offsetからshortを求める
knight moveは0にしたいが,Board_Tableには対応するものはない
Definition at line 81 of file pieceEval.tcc.
References osl::Board_Table, osl::dirToMask(), osl::Move::from(), osl::BoardTable::getLongDirection(), osl::PtypeTable::getMoveMask(), osl::BoardTable::getShortOffsetNotKnight(), osl::Piece::isOnBoardByOwner(), osl::Piece::ptype(), osl::Ptype_Table, osl::Move::to(), and osl::Offset::zero().