• R/O
  • HTTP
  • SSH
  • HTTPS

Commit

Tags
Aucun tag

Frequently used words (click to add to your profile)

javac++androidlinuxc#windowsobjective-ccocoa誰得qtpythonphprubygameguibathyscaphec計画中(planning stage)翻訳omegatframeworktwitterdomtestvb.netdirectxゲームエンジンbtronarduinopreviewer

shogi-server source


Commit MetaInfo

Révisionf565a12329d70a6917348483d655b5e9bd383ee0 (tree)
l'heure2013-12-17 22:46:22
AuteurDaigo Moriwaki <daigo@debi...>
CommiterDaigo Moriwaki

Message de Log

Fixed issues on usiToCsa.rb.

- Corrected type of TORYO
- Corrected keep alive packet

Change Summary

Modification

--- a/bin/usiToCsa.rb
+++ b/bin/usiToCsa.rb
@@ -372,7 +372,7 @@ class BridgeState
372372
373373 case str.strip
374374 when /^bestmove\s+resign/
375- server_puts "%TYORO"
375+ server_puts "%TORYO"
376376 when /^bestmove\swin/
377377 server_puts "%KACHI"
378378 when /^bestmove\s+(.*)/
@@ -522,6 +522,7 @@ end
522522 def server_puts(str)
523523 log_server_send str
524524 $server.puts str
525+ $bridge_state.update_last_server_send_time
525526 end
526527
527528 # Start an engine process
@@ -613,9 +614,9 @@ def main_loop
613614 ret, = select([$server, $engine], nil, nil, 60)
614615 unless ret
615616 # Send keep-alive
616- if @bridge_state.too_quiet?
617+ if $bridge_state.too_quiet?
617618 $server.puts ""
618- @bridge_state.update_last_server_send_time
619+ $bridge_state.update_last_server_send_time
619620 end
620621 next
621622 end