fix chess960 castling edge case