diff --git a/Chess/nimfish.nimble b/Chess/nimfish.nimble index 80533ac..db8a89b 100644 --- a/Chess/nimfish.nimble +++ b/Chess/nimfish.nimble @@ -16,7 +16,6 @@ requires "nim >= 2.0.4" requires "jsony >= 1.1.5" requires "nint128 >= 0.3.3" requires "nimpy >= 0.2.0" -requires "scinim >= 0.2.5" task test, "Runs the test suite": diff --git a/Chess/nimfish/nimfishpkg/uci.nim b/Chess/nimfish/nimfishpkg/uci.nim index 2686e68..167b8da 100644 --- a/Chess/nimfish/nimfishpkg/uci.nim +++ b/Chess/nimfish/nimfishpkg/uci.nim @@ -46,7 +46,6 @@ type historyTable: ptr HistoryTable # Storage for our killer move heuristic killerMoves: ptr KillersTable - ponderMove: ptr Move UCICommandType = enum ## A UCI command type enumeration @@ -337,12 +336,10 @@ proc bestMove(args: tuple[session: UCISession, command: UCICommand]) {.thread.} elif timeRemaining == 0: timeRemaining = int32.high() var line = searcher.findBestLine(timeRemaining, increment, command.depth, command.nodes, command.searchmoves, timePerMove, command.ponder) - if session.ponderMove[] == nullMove(): - if line.len() == 1: - echo &"bestmove {line[0].toAlgebraic()}" - else: - session.ponderMove[] = line[1] - echo &"bestmove {line[0].toAlgebraic()} ponder {line[1].toAlgebraic()}" + if line.len() == 1: + echo &"bestmove {line[0].toAlgebraic()}" + else: + echo &"bestmove {line[0].toAlgebraic()} ponder {line[1].toAlgebraic()}" proc startUCISession* = @@ -363,8 +360,6 @@ proc startUCISession* = session.transpositionTable[] = newTranspositionTable(session.hashTableSize * 1024 * 1024) session.historyTable = cast[ptr HistoryTable](alloc0(sizeof(HistoryTable))) session.killerMoves = cast[ptr KillersTable](alloc0(sizeof(KillersTable))) - session.ponderMove = cast[ptr Move](alloc(sizeof(Move))) - session.ponderMove[] = nullMove() # (Re-)Initialize history table for color in PieceColor.White..PieceColor.Black: for i in Square(0)..Square(63): @@ -428,11 +423,6 @@ proc startUCISession* = echo "info string ponder move has been hit" if not session.searchFlag[].load(): continue - var b = newChessboardFromFEN(session.position.toFEN()) - b.makeMove(session.ponderMove[]) - session.position = b.position - session.ponderMove[] = nullMove() - session.stopFlag[].store(true) joinThread(searchThread) if session.debug: echo "info string ponder search stopped" @@ -440,7 +430,6 @@ proc startUCISession* = if session.debug: echo "info string search started" of Go: - session.ponderMove[] = nullMove() when not defined(historyPenalty): # Scale our history coefficients for color in PieceColor.White..PieceColor.Black: