From 4f1d55fb8a93b02d97850337a5d7fce935f3b5f0 Mon Sep 17 00:00:00 2001 From: tslil clingman Date: Thu, 21 Jan 2021 00:18:33 -0500 Subject: Unrelated --- include/minimax_cnn1986.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/include/minimax_cnn1986.c b/include/minimax_cnn1986.c index e89e5a6..fed30e2 100644 --- a/include/minimax_cnn1986.c +++ b/include/minimax_cnn1986.c @@ -155,7 +155,8 @@ static enum WIN_TYPE w; } else if (cur_depth == max_depth) { \ /* We're at the bottom, evaluate */ \ val = ct1986_evaluate_black_win(); \ - if ((ply & 1) == 0) val = val - 1.0; \ + if ((ply & 1) == 0) val = 1.0 - 2*val; \ + if (min) val *= -1; \ } else { \ /* We're not at the bottom, recurse first */ \ next_ply(); \ -- cgit v1.2.3