18 if (property == 0 || property == 1) {
21 return property == openLong(state, move);
31 std::ostringstream os;
32 os <<
"B" << self << opponent;
38 std::ostringstream os;
39 os <<
"Open" <<
property / 4 <<
property % 4;
72 if (move.
ptype() != self)
77 if (last_move.
ptype() != attack)
79 const Square last_to = last_move.
to();
80 if (last_to==move.
to())
83 Test action(&result, state, move);
94 const Square last_to = last_move.
to();
95 if (last_to==move.
to())
102 Test action(&result, state, move);
118#if OSL_WORDSIZE == 32
142 +(opponent_type == CAPTURE ?
"c" : (opponent_type == DROP ?
"d" :
"e"));
PtypeO ptypeO() const
移動後のPtype, i.e., 成る手だった場合成った後
bool isNormal() const
INVALID でも PASS でもない.
bool isOpenCheck(Move move) const
const PieceMask effectedMask(Player pl) const
pl からの利きが(1つ以上)ある駒一覧
bool hasEffectByPiece(Piece attack, Square target) const
駒attack が target に利きを持つか (旧hasEffectToと統合)
bool isDirectCheck(Move move) const
bool hasEffectIf(PtypeO ptypeo, Square attacker, Square target) const
attackerにptypeoの駒がいると仮定した場合にtargetに利きがあるかどうか を stateをupdateしないで確かめる.
void forEachEffectOfPiece(Square pieceSquare, Action &action) const
pieceSquareにある駒によって利きを受けるすべてのsquare (空白含む)について actionを実行する
const PieceMask & piecesOnBoard(Player p) const
const mask_t getMask(int num) const
const Square square() const
bool isOnBoardByOwner() const
piece がプレイヤーPの持ち物でかつボード上にある駒の場合は true.
bool hasLongMove(Ptype ptype) const
遅くて良い?
const char * getCsaName(Ptype ptype) const
const Piece pieceOnBoard(Square sq) const
const Piece pieceOf(int num) const
const Piece pieceAt(Square sq) const
const Move lastMove(size_t last=1) const
bool match(const NumEffectState &state, Move move, const RatingEnv &) const
static const CArray< const char *, 4 > check_property
const std::string & name() const
const PtypeTable Ptype_Table
constexpr Player alt(Player player)