projects
/
fairystockfish.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
(parent:
b65879c
)
Revise palace attacks for rook
author
Fabian Fichter
<ianfab@users.noreply.github.com>
Wed, 16 Sep 2020 20:13:01 +0000 (22:13 +0200)
committer
Fabian Fichter
<ianfab@users.noreply.github.com>
Wed, 16 Sep 2020 20:13:01 +0000 (22:13 +0200)
janggi
Total: 500 W: 268 L: 221 D: 11
src/evaluate.cpp
patch
|
blob
|
history
diff --git
a/src/evaluate.cpp
b/src/evaluate.cpp
index
f91626f
..
6d01a5a
100644
(file)
--- a/
src/evaluate.cpp
+++ b/
src/evaluate.cpp
@@
-303,7
+303,7
@@
namespace {
{
// Find attacked squares, including x-ray attacks for bishops and rooks
b = Pt == BISHOP ? attacks_bb<BISHOP>(s, pos.pieces() ^ pos.pieces(QUEEN))
- : Pt == ROOK ? attacks_bb< ROOK>(s, pos.pieces() ^ pos.pieces(QUEEN) ^ pos.pieces(Us, ROOK))
+ : Pt == ROOK && !pos.diagonal_lines() ? attacks_bb< ROOK>(s, pos.pieces() ^ pos.pieces(QUEEN) ^ pos.pieces(Us, ROOK))
: pos.attacks_from(Us, Pt, s);
// Restrict mobility to actual squares of board