if (board_bb(c, pt) & s)
{
PieceType move_pt = pt == KING ? king_type() : pt;
- // Consider asymmetrical move of horse
+ // Consider asymmetrical moves (e.g., horse)
if (AttackRiderTypes[move_pt] & ASYMMETRICAL_RIDERS)
{
- Bitboard horses = PseudoAttacks[~c][move_pt][s] & pieces(c, pt);
- while (horses)
+ Bitboard asymmetricals = PseudoAttacks[~c][move_pt][s] & pieces(c, pt);
+ while (asymmetricals)
{
- Square s2 = pop_lsb(&horses);
+ Square s2 = pop_lsb(&asymmetricals);
if (attacks_bb(c, move_pt, s2, occupied) & s)
b |= s2;
}
janggiCannons ^= to;
// Is there a discovered check?
- if ( ((type_of(m) != DROP && (blockers_for_king(~sideToMove) & from)) || pieces(sideToMove, CANNON, BANNER)
- || pieces(HORSE, ELEPHANT) || pieces(JANGGI_CANNON, JANGGI_ELEPHANT))
+ if ( ((type_of(m) != DROP && (blockers_for_king(~sideToMove) & from)) || (non_sliding_riders() & pieces(sideToMove)))
&& attackers_to(square<KING>(~sideToMove), (type_of(m) == DROP ? pieces() : pieces() ^ from) | to, sideToMove, janggiCannons))
return true;