misc
This commit is contained in:
parent
faccfbc1c5
commit
192aef1ce7
1 changed files with 6 additions and 5 deletions
|
|
@ -976,11 +976,6 @@ impl Position {
|
|||
| d.knight(king_square) & theirs.knight()
|
||||
| x & theirs.bishop()
|
||||
| y & theirs.rook();
|
||||
let blockers_x_ray = blockers & !(x | y);
|
||||
let pinned = (d.bishop(king_square, blockers_x_ray) & theirs.bishop()
|
||||
| d.rook(king_square, blockers_x_ray) & theirs.rook())
|
||||
.map(|sq| d.segment(king_square, sq))
|
||||
.reduce_or();
|
||||
|
||||
if visitor.roles(Role::King) && global_mask_from.contains(king_square) {
|
||||
let attacked = {
|
||||
|
|
@ -1058,6 +1053,12 @@ impl Position {
|
|||
return;
|
||||
}
|
||||
|
||||
let blockers_x_ray = blockers & !(x | y);
|
||||
let pinned = (d.bishop(king_square, blockers_x_ray) & theirs.bishop()
|
||||
| d.rook(king_square, blockers_x_ray) & theirs.rook())
|
||||
.map(|sq| d.segment(king_square, sq))
|
||||
.reduce_or();
|
||||
|
||||
let checker = checkers.first();
|
||||
let block_check = checker
|
||||
.map(|checker| d.segment(king_square, checker))
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue