From: Fabian Fichter Date: Tue, 4 Feb 2020 21:15:10 +0000 (+0100) Subject: Extend range of skill levels to negative values X-Git-Url: http://winboard.nl/cgi-bin?a=commitdiff_plain;h=2329160e944a27e3f97746c4b33d383b503e1cce;p=fairystockfish.git Extend range of skill levels to negative values --- diff --git a/src/search.cpp b/src/search.cpp index 759036c..2e442a7 100644 --- a/src/search.cpp +++ b/src/search.cpp @@ -97,7 +97,7 @@ namespace { struct Skill { explicit Skill(int l) : level(l) {} bool enabled() const { return level < 20; } - bool time_to_pick(Depth depth) const { return depth == 1 + level; } + bool time_to_pick(Depth depth) const { return depth == 1 + std::max(level, 0); } Move pick_best(size_t multiPV); int level; diff --git a/src/ucioption.cpp b/src/ucioption.cpp index f296bb6..e29b062 100644 --- a/src/ucioption.cpp +++ b/src/ucioption.cpp @@ -133,7 +133,7 @@ void init(OptionsMap& o) { o["Clear Hash"] << Option(on_clear_hash); o["Ponder"] << Option(false); o["MultiPV"] << Option(1, 1, 500); - o["Skill Level"] << Option(20, 0, 20); + o["Skill Level"] << Option(20, -20, 20); o["Move Overhead"] << Option(30, 0, 5000); o["Minimum Thinking Time"] << Option(20, 0, 5000); o["Slow Mover"] << Option(84, 10, 1000);