if (!$engine->{'seen_uciok'}) {
# Gobble up lines until we see uciok.
- if ($line =~ /^uciok$/) {
+ if ($line =~ /^id (\S+) (.*)$/) {
+ $engine->{'id'}->{$1} = $2;
+ } elsif ($line =~ /^uciok$/) {
$engine->{'seen_uciok'} = 1;
}
} else {
</ul>
<p id="credits"><a href="http://git.sesse.net/?p=remoteglot;a=summary">remoteglot</a>
© 2007–2014 <a href="http://www.sesse.net/">Steinar H. Gunderson</a>.
- Chess analysis by <a href="http://stockfishchess.org/">Stockfish</a> (main analysis: 20x2.27GHz Haswell-EP,
+ Chess analysis by <a href="http://stockfishchess.org/" id="engineid">Stockfish</a> (main analysis: 20x2.27GHz Haswell-EP,
multi-PV search: 12x2.3GHz Sandy Bridge).
Moves provided by <a href="http://live.fide.com/sochi/">FIDE</a>.
Hosting and multi-PV analysis hardware by <a href="http://www.samfundet.no/">Studentersamfundet i Trondhjem</a>.
$("#numviewers").text(num_viewers + " current viewers");
}
+ // The engine id.
+ if (data['id'] && data['id']['name'] !== null) {
+ $("#engineid").text(data['id']['name']);
+ }
+
// The score.
if (data['score'] !== null) {
$("#score").text(data['score']);