X-Git-Url: https://git.sesse.net/?p=remoteglot;a=blobdiff_plain;f=remoteglot.pl;h=f36a0504b58f60a4fa49bca1d139676ea55f1d5d;hp=a6de634d9f3e43bfc92be254e74ba608662cf76e;hb=31892863fc50b36fbbfa29f7d66088cd1f0ef47b;hpb=f854f5749daf71202c119362544b163e17296d9b diff --git a/remoteglot.pl b/remoteglot.pl index a6de634..f36a050 100755 --- a/remoteglot.pl +++ b/remoteglot.pl @@ -18,17 +18,21 @@ use warnings; # Configuration my $server = "freechess.org"; -my $target = "278"; +my $target = "GMCarlsen"; # my $engine = "/usr/games/toga2"; -# my $engine = "wine Rybkav2.3.2a.mp.w32.exe"; -my $engine = "~/microwine-0.2/microwine Rybkav2.3.2a.mp.x64.exe"; +#my $engine = "wine Rybkav2.3.2a.mp.w32.exe"; +my $engine = "~/microwine-0.5/microwine Rybkav2.3.2a.mp.x64.exe"; +#my $engine = "ssh -t sesse\@84.48.204.209 ./microwine-0.5/microwine ./Rybkav2.3.2a.mp.x64.exe"; +#my $engine = "ssh -t sesse\@cirkus.samfundet.no nice -n 19 ./microwine-0.5/microwine ./microwine-0.5/Rybkav2.3.2a.mp.x64.exe"; my $telltarget = undef; # undef to be silent my @tell_intervals = (5, 20, 60, 120, 240, 480, 960); # after each move -my $uci_assume_full_compliance = 1; # dangerous :-) +my $uci_assume_full_compliance = 0; # dangerous :-) my @masters = ( 'Sesse', 'Sessse', - 'Sesssse' + 'Sesssse', + 'greatestguns', + 'beuki' ); # Program starts here @@ -68,7 +72,7 @@ while () { uciprint("setoption name UCI_AnalyseMode value true"); # uciprint("setoption name Preserve Analysis value true"); -uciprint("setoption name NalimovPath value /srv/tablebase"); +# uciprint("setoption name NalimovPath value /srv/tablebase"); uciprint("setoption name NalimovUsage value Rarely"); uciprint("setoption name Hash value 1024"); uciprint("setoption name MultiPV value 2"); @@ -82,7 +86,7 @@ print "Chess engine ready.\n"; my $t = Net::Telnet->new(Timeout => 10, Prompt => '/fics% /'); $t->input_log(\*FICSLOG); $t->open($server); -$t->print("guest"); +$t->print("SesseBOT"); $t->waitfor('/Press return to enter the server/'); $t->cmd(""); @@ -333,6 +337,7 @@ sub style12_to_fen { $castling .= "k" if ($x[13] == 1); $castling .= "q" if ($x[14] == 1); $castling = "-" if ($castling eq ""); + # $castling = "-"; # chess960 $fen .= " "; $fen .= $castling; @@ -400,7 +405,7 @@ sub prettyprint_pv { my $piece = substr($board->[$from_row], $from_col, 1); if ($piece eq '-') { - die "Invalid move"; + die "Invalid move $pv"; } # white short castling @@ -653,7 +658,7 @@ sub output_screen { $text .= "\n\n"; } - $text .= book_info($pos_calculating->{'fen'}, $pos_calculating->{'board'}, $pos_calculating->{'toplay'}); + #$text .= book_info($pos_calculating->{'fen'}, $pos_calculating->{'board'}, $pos_calculating->{'toplay'}); if ($last_text ne $text) { print ""; # clear the screen @@ -966,7 +971,7 @@ sub book_info { } my $ret = `./booklook $fen`; - return '' if ($ret =~ /Not found/ || $ret eq ''); + return "" if ($ret =~ /Not found/ || $ret eq ''); my @moves = ();