Fix a skill level problem: Don't allow move pruning at root node
authorStefan Geschwentner <stgeschwentner@gmail.com>
Sat, 24 Jan 2015 21:05:06 +0000 (22:05 +0100)
committerJoona Kiiski <joona.kiiski@gmail.com>
Sun, 25 Jan 2015 21:57:13 +0000 (21:57 +0000)
Bench: 8918745

Resolves #231

src/search.cpp

index da306a1..0ce836f 100644 (file)
@@ -831,7 +831,8 @@ moves_loop: // When in check and at SpNode search starts from here
       newDepth = depth - ONE_PLY + extension;
 
       // Step 13. Pruning at shallow depth
-      if (   !captureOrPromotion
+      if (   !RootNode
+          && !captureOrPromotion
           && !inCheck
           && !dangerous
           &&  bestValue > VALUE_MATED_IN_MAX_PLY)