For pieces which move and capture in different ways,
the pseudo-legal move validation needs to take into account
whether a move is a capture or not.
This fixes the pseudo-legal move validation for breakthrough and hoppelpoppel.
breakthrough
ELO: 372.25 +-109.6 (95%) LOS: 100.0%
Total: 100 W: 86 L: 7 D: 7
hoppelpoppel
ELO: 530.72 +-154.4 (95%) LOS: 100.0%
Total: 100 W: 92 L: 1 D: 7
&& double_step_enabled()))
return false;
}
- else if (!(attacks_from(us, type_of(pc), from) & to))
+ else if (!((capture(m) ? attacks_from(us, type_of(pc), from) : moves_from(us, type_of(pc), from)) & to))
return false;
// Evasions generator already takes care to avoid some kind of illegal moves