My Project
openCheck.h
Go to the documentation of this file.
1/* openCheck.h
2 */
3#ifndef _MOVE_CLASSIFIER_OPENCHECK_H
4#define _MOVE_CLASSIFIER_OPENCHECK_H
5
9
10namespace osl
11{
12 namespace move_classifier
13 {
14 template <Player P>
15 struct OpenCheck
16 {
17 static bool isMember(const NumEffectState& state,
18 Ptype ptype,Square from,Square to)
19 {
20 return KingOpenMove<alt(P)>::isMember(state,ptype,from,to);
21 }
22 };
23
24 template <Player P> struct ClassifierTraits<OpenCheck<P> >
25 {
26 static const bool drop_suitable = false;
27 static const bool result_if_drop = false;
28 };
29 } // namespace move_classifier
30} // namespace osl
31
32#endif /* _MOVE_CLASSIFIER_OPENCHECK_H */
33// ;;; Local Variables:
34// ;;; mode:c++
35// ;;; c-basic-offset:2
36// ;;; End:
利きを持つ局面
Ptype
駒の種類を4ビットでコード化する
Definition basic_type.h:84
constexpr Player alt(Player player)
Definition basic_type.h:13
Pの王をopen checkにする手でないことをチェック.
static bool isMember(const NumEffectState &state, Ptype ptype, Square from, Square to)
Definition openCheck.h:17