11 return target.
isOnBoard() && state.hasEffectIf(ptypeo, from, target);
23 if (abs(from.
y() - target.
y()) > 4)
25 if (abs(from.
x() - target.
x()) > 3)
28 else if (ptype ==
LANCE)
30 if (abs(from.
x() - target.
x()) > 2)
35 return hasEffectFromTo(state, ptypeo, from, target,
newOffset(-2,-2))
36 || hasEffectFromTo(state, ptypeo, from, target,
newOffset(-1,-2))
37 || hasEffectFromTo(state, ptypeo, from, target,
newOffset(-0,-2))
38 || hasEffectFromTo(state, ptypeo, from, target,
newOffset( 1,-2))
39 || hasEffectFromTo(state, ptypeo, from, target,
newOffset( 2,-2))
40 || hasEffectFromTo(state, ptypeo, from, target,
newOffset(-2,-1))
41 || hasEffectFromTo(state, ptypeo, from, target,
newOffset(-1,-1))
42 || hasEffectFromTo(state, ptypeo, from, target,
newOffset( 0,-1))
43 || hasEffectFromTo(state, ptypeo, from, target,
newOffset( 1,-1))
44 || hasEffectFromTo(state, ptypeo, from, target,
newOffset( 2,-1))
45 || hasEffectFromTo(state, ptypeo, from, target,
newOffset(-2, 0))
46 || hasEffectFromTo(state, ptypeo, from, target,
newOffset(-1, 0))
47 || hasEffectFromTo(state, ptypeo, from, target,
newOffset( 0, 0))
48 || hasEffectFromTo(state, ptypeo, from, target,
newOffset( 1, 0))
49 || hasEffectFromTo(state, ptypeo, from, target,
newOffset( 2, 0))
50 || hasEffectFromTo(state, ptypeo, from, target,
newOffset(-2, 1))
51 || hasEffectFromTo(state, ptypeo, from, target,
newOffset(-1, 1))
52 || hasEffectFromTo(state, ptypeo, from, target,
newOffset( 0, 1))
53 || hasEffectFromTo(state, ptypeo, from, target,
newOffset( 1, 1))
54 || hasEffectFromTo(state, ptypeo, from, target,
newOffset( 2, 1))
55 || hasEffectFromTo(state, ptypeo, from, target,
newOffset(-2, 2))
56 || hasEffectFromTo(state, ptypeo, from, target,
newOffset(-1, 2))
57 || hasEffectFromTo(state, ptypeo, from, target,
newOffset( 0, 2))
58 || hasEffectFromTo(state, ptypeo, from, target,
newOffset( 1, 2))
59 || hasEffectFromTo(state, ptypeo, from, target,
newOffset( 2, 2));