Documentation ¶
Index ¶
- type EntryConf
- func (config EntryConf) Apply() bool
- func (config EntryConf) AvailableTimeMinutes() uint
- func (config EntryConf) BoardSize() uint
- func (config EntryConf) CanadianTiming() uint
- func (config EntryConf) EngineCommand() string
- func (config EntryConf) EngineCommandOption() string
- func (config EntryConf) Host() string
- func (config EntryConf) Opponent() string
- func (config EntryConf) Pass() string
- func (config EntryConf) Phase() string
- func (config EntryConf) PlayerType() string
- func (config EntryConf) Port() uint
- func (config EntryConf) User() string
- type MatchApplication
- type Nngs
- type NngsGtpController
- type NngsHumanController
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type EntryConf ¶
type EntryConf struct { Nngs Nngs MatchApplication MatchApplication }
EntryConf - 参加設定。
func (EntryConf) Apply ¶
Apply - 自分の方から申し込むなら true, 申し込みを受けるのを待つ方なら false。 true にしたなら、 Opponent も設定してください
func (EntryConf) AvailableTimeMinutes ¶
AvailableTimeMinutes - 持ち時間(分)
func (EntryConf) CanadianTiming ¶
CanadianTiming - カナダ式秒読み。25手を何分以内に打てばよいか
func (EntryConf) EngineCommand ¶
EngineCommand - 思考エンジンを起動するコマンドの実行ファイル名の部分(OSにより書き方が異なるかも)
func (EntryConf) EngineCommandOption ¶
EngineCommandOption - 思考エンジンを起動するコマンドの半角スペース区切りの引数(OSにより書き方が異なるかも)
func (EntryConf) PlayerType ¶
PlayerType - プレイヤーの種類 * `Human` - 人間プレイヤーが接続する * `GTP` - GTP(碁テキスト プロトコル)を用いる思考エンジンが接続する
type MatchApplication ¶
type MatchApplication struct { Apply bool Opponent string Phase string BoardSize int64 AvailableTimeMinutes int64 CanadianTiming int64 }
MatchApplication - MatchApplication 区画。
type Nngs ¶
type Nngs struct { PlayerType string Host string Port int64 // Tomlのライブラリーが精度を細かく指定できないので int64 型で。 User string Pass string EngineCommand string EngineCommandOption string }
Nngs - Nngs 区画。
type NngsGtpController ¶
type NngsGtpController struct { e.NngsListener // EngineIO - GTPプロトコル対応のコンピューター囲碁ソフト(外部プロセス)との入出力に利用 EngineIO exec.Cmd // EntryConf - 参加設定 EntryConf EntryConf }
NngsGtpController - NNGS からの受信メッセージをさばきます。
func (NngsGtpController) NoticeMyPhase ¶
func (con NngsGtpController) NoticeMyPhase()
NoticeMyPhase - 自分の手番であることのアナウンスが来ました。 この通知を受け取ったら、思考を開始してください。 指し手の入力をするには、別途、非同期の出力で 返してください Original code: nngsCUI.rb/announce class/update/`when 'my_turn'`
func (NngsGtpController) NoticeOpponentPhase ¶
func (con NngsGtpController) NoticeOpponentPhase()
NoticeOpponentPhase - 相手の手番であることのアナウンス Original code: nngsCUI.rb/announce class/update/`when 'his_turn'`
type NngsHumanController ¶
type NngsHumanController struct { e.NngsListener // EntryConf - 参加設定 EntryConf EntryConf }
NngsHumanController - NNGS からの受信メッセージをさばきます。
func (NngsHumanController) NoticeMyPhase ¶
func (con NngsHumanController) NoticeMyPhase()
NoticeMyPhase - 自分の手番であることのアナウンスが来ました。 この通知を受け取ったら、思考を開始してください。 指し手の入力をするには、別途、非同期の出力で 返してください Original code: nngsCUI.rb/announce class/update/`when 'my_turn'`
func (NngsHumanController) NoticeOpponentPhase ¶
func (con NngsHumanController) NoticeOpponentPhase()
NoticeOpponentPhase - 相手の手番であることのアナウンス Original code: nngsCUI.rb/announce class/update/`when 'his_turn'`