Go to the documentation of this file.
27 if (move.
ptype() !=
self)
62 for (
int dx=-1; dx<=1; ++dx) {
63 for (
int dy=-1; dy<=1; ++dy) {
64 if (dx == 0 && dy ==0)
72 if (king.
x() == 1 || king.
x() == 9)
116 if (move.
ptype() !=
self)
const Piece pieceAt(Square sq) const
int min(Player p, int v1, int v2)
AttackKing8(Ptype s, Ptype t, bool ss, int attack, int defense)
bool match(const NumEffectState &state, Move move, const RatingEnv &env) const
static bool blocking(const NumEffectState &state, Square king, Square to)
constexpr Player alt(Player player)
static bool matchMove(const NumEffectState &state, Move move)
static Square findNearest(const NumEffectState &state, PtypeO ptypeo, Square from, Square target)
static bool matchDrop(const NumEffectState &state, Move move)
const std::string & name() const
PtypeO newPtypeO(Player player, Ptype ptype)
static int count(const NumEffectState &state)
bool hasEffectAt(Square target) const
対象とするマスにあるプレイヤーの利きがあるかどうか.
bool match(const NumEffectState &state, Square position, const RatingEnv &env) const
const Piece findAttackAt(Player attack, Square target) const
return a piece s.t.
const Piece pieceOnBoard(Square sq) const
bool isPieceStand() const
PtypeO ptypeO() const
移動後のPtype, i.e., 成る手だった場合成った後
bool hasEffectByPiece(Piece attack, Square target) const
駒attack が target に利きを持つか (旧hasEffectToと統合)
bool match(const NumEffectState &state, Move move, const RatingEnv &) const
const Square from() const
int x() const
将棋としてのX座標を返す.
DefenseKing8(Ptype s, bool d, int dan)
constexpr bool isPiece(Ptype ptype)
ptypeが空白やEDGEでないかのチェック
Square kingSquare() const
bool isNeighboring8(Square to) const
const Square square() const
static bool hasEffect(const NumEffectState &state, PtypeO ptypeo, Square from, Square target)
ptypeo の駒がfromからtargetの8近傍に直接の利きを持つか