mirror of
https://github.com/sockspls/badfish
synced 2025-04-30 16:53:09 +00:00
Fix search log when using skills
In case of we pick a sub-optimal move be sure to print this, and not the best one on seach log file. Bug spotted by Guenther Demetz. No functional change.
This commit is contained in:
parent
2a98042c21
commit
05c6f7a40b
1 changed files with 5 additions and 1 deletions
|
@ -416,8 +416,12 @@ namespace {
|
|||
|
||||
if (Options["Use Search Log"])
|
||||
{
|
||||
RootMove& rm = RootMoves[0];
|
||||
if (skill.best != MOVE_NONE)
|
||||
rm = *std::find(RootMoves.begin(), RootMoves.end(), skill.best);
|
||||
|
||||
Log log(Options["Search Log Filename"]);
|
||||
log << pretty_pv(pos, depth, bestValue, Time::now() - SearchTime, &RootMoves[0].pv[0])
|
||||
log << pretty_pv(pos, depth, rm.score, Time::now() - SearchTime, rm.pv.data())
|
||||
<< std::endl;
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue