shadowEffect.cc
Go to the documentation of this file.
3 #include "osl/additionalEffect.h"
4 
5 template <int count_max>
8  Player attack)
9 {
10  PieceVector direct_pieces;
11  state.findEffect(alt(attack), target, direct_pieces);
12  return AdditionalOrShadow::count<count_max>
13  (direct_pieces, state, target, attack);
14 }
15 
18  Player attack)
19 {
20  return count<1>(state, target, attack);
21 }
22 
25  Player attack)
26 {
27  return count<2>(state, target, attack);
28 }
29 
30 
31 // ;;; Local Variables:
32 // ;;; mode:c++
33 // ;;; c-basic-offset:2
34 // ;;; End:
constexpr Player alt(Player player)
Definition: basic_type.h:13
static int count(const NumEffectState &, Square target, Player attack)
Definition: shadowEffect.cc:7
static int count2(const NumEffectState &, Square target, Player attack)
target に attack の影利きを二つまで数える.
Definition: shadowEffect.cc:24
利きを持つ局面
void findEffect(Player P, Square target, PieceVector &out) const
target に利きのあるPieceをoutに格納する
static bool hasEffect(const NumEffectState &, Square target, Player attack)
target に attack の影利きが一つでもあるか. 相手の追加利きが先にある場合は対象としない. ...
Definition: shadowEffect.cc:17
Player
Definition: basic_type.h:8