X-Git-Url: https://git.sesse.net/?p=remoteglot;a=blobdiff_plain;f=remoteglot.pl;h=00e470763fafeb65ee56ea62ebdf7c33697aa67d;hp=2b81e5c9566bd2ae7c6069e2401407ed7ef1486d;hb=97c70de23489ac17e367dbe2b7abaece5c740343;hpb=269776b172ada8c902a65780353ec8fe2c1e4ff8 diff --git a/remoteglot.pl b/remoteglot.pl index 2b81e5c..00e4707 100755 --- a/remoteglot.pl +++ b/remoteglot.pl @@ -346,6 +346,9 @@ sub handle_position { # ignore it. if (defined($pos_calculating) && $pos->fen() eq $pos_calculating->fen()) { $pos_calculating->{'result'} = $pos->{'result'}; + for my $key ('white_clock', 'black_clock', 'white_clock_target', 'black_clock_target') { + $pos_calculating->{$key} //= $pos->{$key}; + } return; } @@ -564,6 +567,7 @@ sub complete_using_tbprobe { # Splice the PV from the tablebase onto what we have so far. for my $move (@{$pgn->moves}) { + last if $move eq '#'; my $uci_move; ($pos, $uci_move) = $pos->make_pretty_move($move); push @moves, $uci_move; @@ -1335,7 +1339,7 @@ sub schedule_tb_lookup { return if ($tb_lookup_running); $tb_lookup_running = 1; - my $url = 'http://158.250.18.203:6904/tasks/addtask?auth.login=' . + my $url = 'http://tb7-api.chessok.com:6904/tasks/addtask?auth.login=' . $remoteglotconf::tb_serial_key . '&auth.password=aquarium&type=0&fen=' . URI::Escape::uri_escape($pos->fen());