Bugfix cross-engine play test mode selection
If you attempt to set a test mode for the dev engine, which the base engine does not have, we produce errors. The only reason we need to check the base engine's understanding of the test mode is to set Base Options. We can fall back to the STC settings, since we already copy the Threads= and Hash= portion from the Dev options
This commit is contained in:
1 parent
05be69c9dd
commit
bc26be7a4c
1 file changed
+6
-2
@@ -110,9 +110,13 @@ function set_test_type() {
|
||||
|
||||
function set_engine_options(mode_str, target) {
|
||||
|
||||
// Fall back to STC, which tends to exist. Needed for cross-engine play
|
||||
var dev_mode = extract_mode_config(mode_str, 'dev' ) || extract_mode_config('STC', 'dev' );
|
||||
var base_mode = extract_mode_config(mode_str, 'base') || extract_mode_config('STC', 'base');
|
||||
|
||||
// Extract UCI options for both the Dev and Base engines
|
||||
var dev_options = extract_mode_config(mode_str, 'dev' )['options'] || 'Threads=1 Hash=8';
|
||||
var base_options = extract_mode_config(mode_str, 'base')['options'] || 'Threads=1 Hash=8';
|
||||
var dev_options = dev_mode ? dev_mode['options'] : 'Threads=1 Hash=8';
|
||||
var base_options = base_mode ? base_mode['options'] : 'Threads=1 Hash=8';
|
||||
|
||||
// Simple case, where we are not updating a base that is cross-engine
|
||||
if (target == 'dev' || dev_options == base_options)
|
||||
|
||||
Reference in new issue
Block a user