4template <osl::Player P>
5template <
bool hasException>
11 Square king_position=state.template kingSquare<P>();
17 assert(king_position != from);
29 if(!state.
isEmptyBetween(from,king_position,offset,
true))
return false;
32 for(pos-=offset;;pos-=offset){
34 if (! ((hasException && (pos == exceptFor))
bool isOnBoardByOwner() const
piece がプレイヤーPの持ち物でかつボード上にある駒の場合は true.
bool isEmptyBetween(Square from, Square to, Offset offset, bool pieceExistsAtTo=false) const
const Piece pieceAt(Square sq) const
bool isPieceStand() const
bool isOnBoard() const
盤面上を表すかどうかの判定. 1<=x() && x()<=9 && 1<=y() && y()<=9 Squareの内部表現に依存する.
const PtypeTable Ptype_Table
const BoardTable Board_Table
Offset32Base< 8, 9 > Offset32
constexpr Player alt(Player player)
Pの王をopen checkにする手でないことをチェック.
static bool isMemberMain(const NumEffectState &state, Ptype ptype, Square from, Square to, Square exceptFor)