summaryrefslogtreecommitdiffstats
path: root/manual/plugins/goban.tex
blob: 4c7ab26f6167807d63899d59d7d438006f91d81f (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
\subsection{Goban}
\screenshot{plugins/images/ss-goban}{Goban}{The Rockbox Goban plugin}
Goban is a a plugin for playing, viewing and recording games of Go (also known
as Weiqi, Baduk, Igo and Goe).  It uses standard Smart Game Format (SGF) files
for saving and loading games.  You can find a short introduction to Go at
\url{http://senseis.xmp.net/?WhatIsGo} and more information about SGF files
can be read at \url{http://senseis.xmp.net/?SmartGameFormat} or the SGF
specification at \url{http://www.red-bean.com/sgf/}.\\

This plugin can load all modern SGF files (file format 3 or 4) with few problems.
It attempts to preserve SGF properties which it doesn't understand, and most common
SGF properties are handled fully.  It is possible to view (and edit if you like)
Kogo's Joseki Dictionary (\url{http://waterfire.us/joseki.htm}) with this plugin,
although the load and save times can be on the order of a minute or two on
particularly slow devices.  Large SGF files may stop audio playback for the duration
of the plugin's run in order to free up more memory and some very large SGF files will
not even load on devices with little available memory.\\

\note{The plugin does \emph{NOT} support SGF files with multiple games in
one file.  These are rare, but if you have one don't even try it (the file will most
likely be corrupted if you save over it). You have been warned.\\}

The file \fname {/sgf/gbn\_def.sgf} is used by the plugin to store any unsaved
changes in the most recently loaded game.  This means that if you forget to save your
changes, you should load \fname {/sgf/gbn\_def.sgf} immediately to offload the changes
to another file.  If you load another file first then your changes will be lost
permanently.  The \fname {/sgf/gbn\_def.sgf} file is also the file loaded if another
is not selected.\\

The information panel which displays the current move number may also contain
these markers:

\begin{table}
    \begin{rbtabular}{\textwidth}{lX}%
      {\textbf{Mark} & \textbf{Meaning}}{}{}
      \emph{+ } & There are nodes after the current node in the SGF tree. \\
      \emph{* } & There are sibling variations which can be navigated to using the %
      \emph{Next Variation} menu option of the \emph{Context Menu}%
      \opt{SANSA_E200_PAD,SANSA_C200_PAD,SANSA_CLIP_PAD,%
         MROBE100_PAD,GIGABEAT_PAD,GIGABEAT_S_PAD,IRIVER_H100_PAD,%
         IRIVER_H300_PAD,PBELL_VIBE500_PAD,MPIO_HD200_PAD,SANSA_FUZEPLUS_PAD,%
         SAMSUNG_YH92X_PAD,SAMSUNG_YH820_PAD}{ or the %
         \opt{SANSA_FUZEPLUS_PAD}{\ButtonBottomRight}%
         \opt{SANSA_E200_PAD,SANSA_C200_PAD}{\ButtonRec}%
         \opt{SANSA_CLIP_PAD}{\ButtonHome}%
         \opt{MROBE100_PAD}{\ButtonPower}%
         \opt{GIGABEAT_PAD}{\ButtonA}%
         \opt{GIGABEAT_S_PAD}{\ButtonPlay}%
         \opt{PBELL_VIBE500_PAD}{\ButtonCancel}%
         \opt{MPIO_HD200_PAD}{Long \ButtonFunc}%
         \opt{MPIO_HD300_PAD}{\ButtonMenu}%
         \opt{SAMSUNG_YH92X_PAD}{\ButtonFF{} + \ButtonUp}
         \opt{SAMSUNG_YH820_PAD}{\ButtonRec{} + \ButtonUp}
         \opt{IRIVER_H100_PAD,IRIVER_H300_PAD}{\ButtonRec} button}. \\
      \emph{C } & There is a comment at the current node.  It can be viewed/edited using
                the \emph{Add/Edit Comment} menu option of the \emph{Context Menu}. \\
    \end{rbtabular}
\end{table}

\subsubsection{Controls}
    \begin{btnmap}
        \nopt{IPOD_1G2G_PAD,IPOD_3G_PAD,IPOD_4G_PAD,IRIVER_H10_PAD,%
            MPIO_HD200_PAD,MPIO_HD300_PAD,touchscreen}{\ButtonUp}%
        \opt{IPOD_1G2G_PAD,IPOD_3G_PAD,IPOD_4G_PAD}{\ButtonMenu}%
        \opt{IRIVER_H10_PAD,MPIO_HD300_PAD}{\ButtonScrollUp}
        \opt{MPIO_HD200_PAD}{\ButtonRew}
        \opt{touchscreen}{\TouchTopMiddle}
            &
        \opt{HAVEREMOTEKEYMAP}{
            &}
        Move cursor up
        \\

        \nopt{IPOD_1G2G_PAD,IPOD_3G_PAD,IPOD_4G_PAD,IRIVER_H10_PAD,%
            MPIO_HD200_PAD,MPIO_HD300_PAD,touchscreen}{\ButtonDown}%
        \opt{IPOD_1G2G_PAD,IPOD_3G_PAD,IPOD_4G_PAD}{\ButtonPlay}%
        \opt{IRIVER_H10_PAD,MPIO_HD300_PAD}{\ButtonScrollDown}
        \opt{MPIO_HD200_PAD}{\ButtonFF}
        \opt{touchscreen}{\TouchBottomMiddle}
            &
        \opt{HAVEREMOTEKEYMAP}{
            &}
        Move cursor down
        \\

        \nopt{MPIO_HD200_PAD,MPIO_HD300_PAD,touchscreen}{\ButtonLeft}
        \opt{MPIO_HD200_PAD}{\ButtonVolDown}
        \opt{MPIO_HD300_PAD}{\ButtonRew}
        \opt{touchscreen}{\TouchMidLeft}
            &
        \opt{HAVEREMOTEKEYMAP}{
            &}
        Move cursor left
        \\

        \nopt{MPIO_HD200_PAD,MPIO_HD300_PAD,touchscreen}{\ButtonRight}
        \opt{MPIO_HD200_PAD}{\ButtonVolUp}
        \opt{MPIO_HD300_PAD}{\ButtonFF}
        \opt{touchscreen}{\TouchMidRight}
            &
        \opt{HAVEREMOTEKEYMAP}{
            &}
        Move cursor right
        \\

        \nopt{IRIVER_H10_PAD,IAUDIO_M3_PAD,PBELL_VIBE500_PAD%
            ,MPIO_HD200_PAD,MPIO_HD300_PAD,SAMSUNG_YH92X_PAD,SAMSUNG_YH820_PAD%
            ,touchscreen}{\ButtonSelect}%
        \opt{IRIVER_H10_PAD,PBELL_VIBE500_PAD,SAMSUNG_YH92X_PAD%
            ,SAMSUNG_YH820_PAD}{\ButtonPlay}%
        \opt{MPIO_HD200_PAD}{\ButtonFunc}
        \opt{MPIO_HD300_PAD}{\ButtonEnter}
        \opt{touchscreen}{\TouchCenter}
            &
        \opt{HAVEREMOTEKEYMAP}{
            &}
        Play a move (or use a tool if play-mode has been changed).
        \\

            \opt{SANSA_E200_PAD,SANSA_FUZE_PAD,IPOD_1G2G_PAD,IPOD_3G_PAD%
                ,IPOD_4G_PAD}{\ButtonScrollBack}%
            \opt{SANSA_CLIP_PAD,SANSA_M200_PAD,SANSA_C200_PAD,GIGABEAT_PAD%
                ,GIGABEAT_S_PAD}{\ButtonVolDown}%
            \opt{IRIVER_H10_PAD}{\ButtonFF}%
            \opt{IRIVER_H100_PAD,IRIVER_H300_PAD}{\ButtonOff}%
            \opt{MROBE100_PAD}{\ButtonMenu}%
            \opt{SANSA_FUZEPLUS_PAD}{\ButtonBack}%
            \opt{IAUDIO_X5_PAD}{\ButtonPlay}%
            \opt{touchscreen}{\TouchBottomLeft}
            \opt{PBELL_VIBE500_PAD}{\ButtonOK{} + \ButtonLeft}
            \opt{MPIO_HD200_PAD,MPIO_HD300_PAD}{\ButtonRec + \ButtonRew}
            \opt{SAMSUNG_YH92X_PAD}{\ButtonFF{} + \ButtonLeft}
            \opt{SAMSUNG_YH820_PAD}{\ButtonRec{} + \ButtonLeft}
                &
            \opt{HAVEREMOTEKEYMAP}{
                &}
            Retreat one node in the game tree
            \\

            \opt{scrollwheel}{\ButtonScrollFwd}%
            \opt{SANSA_CLIP_PAD,SANSA_M200_PAD,SANSA_C200_PAD,GIGABEAT_PAD%
                ,GIGABEAT_S_PAD}{\ButtonVolUp}%
            \opt{IRIVER_H10_PAD}{\ButtonRew}%
            \opt{IRIVER_H100_PAD,IRIVER_H300_PAD}{\ButtonOn}%
            \opt{MROBE100_PAD,SANSA_FUZEPLUS_PAD}{\ButtonPlay}%
            \opt{IAUDIO_X5_PAD}{\ButtonRec}%
            \opt{touchscreen}{\TouchBottomRight}
            \opt{PBELL_VIBE500_PAD}{\ButtonOK{} + \ButtonRight}
            \opt{MPIO_HD200_PAD,MPIO_HD300_PAD}{\ButtonRec + \ButtonFF}
            \opt{SAMSUNG_YH92X_PAD}{\ButtonFF{} + \ButtonRight}
            \opt{SAMSUNG_YH820_PAD}{\ButtonRec{} + \ButtonRight}
                &
            \opt{HAVEREMOTEKEYMAP}{
                &}
            Advance one node in the game tree
            \\

        \opt{SANSA_E200_PAD,SANSA_FUZE_PAD,SANSA_CLIP_PAD,SANSA_M200_PAD%
            ,SANSA_C200_PAD,IRIVER_H10_PAD,IAUDIO_X5_PAD,SANSA_FUZEPLUS_PAD%
            }{\ButtonPower}%
        \opt{MROBE100_PAD}{\ButtonDisplay}%
        \opt{IPOD_1G2G_PAD,IPOD_3G_PAD,IPOD_4G_PAD}{Long \ButtonSelect}%
        \opt{GIGABEAT_PAD,GIGABEAT_S_PAD,PBELL_VIBE500_PAD,MPIO_HD300_PAD}%
            {\ButtonMenu}%
        \opt{IRIVER_H100_PAD,IRIVER_H300_PAD}{\ButtonMode}%
        \opt{MPIO_HD200_PAD}{Long \ButtonPlay}
        \opt{SAMSUNG_YH92X_PAD,SAMSUNG_YH820_PAD}{\ButtonRew}
        \opt{touchscreen}{\TouchTopLeft}
            &
        \opt{HAVEREMOTEKEYMAP}{
            &}
        Main Menu
        \\

        \opt{SANSA_E200_PAD,SANSA_FUZE_PAD,SANSA_C200_PAD,GIGABEAT_PAD,GIGABEAT_S_PAD%
            ,IRIVER_H100_PAD,IRIVER_H300_PAD,MROBE100_PAD,IAUDIO_X5_PAD,IRIVER_H10_PAD%
            ,MPIO_HD200_PAD,PBELL_VIBE500_PAD,touchscreen,SANSA_FUZEPLUS_PAD%
            ,SAMSUNG_YH92X_PAD,SAMSUNG_YH820_PAD}{%
            \nopt{IRIVER_H10_PAD,touchscreen,PBELL_VIBE500_PAD,SAMSUNG_YH92X_PAD,%
                MPIO_HD200_PAD,MPIO_HD300_PAD,SANSA_FUZEPLUS_PAD,SAMSUNG_YH820_PAD}%
                {Long \ButtonSelect}%
            \opt{IRIVER_H10_PAD}{Long \ButtonPlay}
            \opt{touchscreen}{Long \TouchCenter}
            \opt{PBELL_VIBE500_PAD}{\ButtonOK}
            \opt{SANSA_FUZEPLUS_PAD}{\ButtonBottomLeft}
            \opt{MPIO_HD200_PAD}{Long \ButtonFunc}
            \opt{MPIO_HD300_PAD}{Long \ButtonEnter}
            \opt{SAMSUNG_YH92X_PAD,SAMSUNG_YH820_PAD}{Long \ButtonPlay}%
                &
            \opt{HAVEREMOTEKEYMAP}{
                &}
            Context Menu
            \\
        }

        \opt{SANSA_E200_PAD,SANSA_C200_PAD,SANSA_FUZE_PAD,MROBE100_PAD%
            ,GIGABEAT_PAD,GIGABEAT_S_PAD,IRIVER_H100_PAD,IRIVER_H300_PAD,SANSA_CLIP_PAD%
            ,PBELL_VIBE500_PAD,MPIO_HD200_PAD,touchscreen,SANSA_FUZEPLUS_PAD,
            ,SAMSUNG_YH92X_PAD,SAMSUNG_YH820_PAD}{%
            \opt{SANSA_E200_PAD,SANSA_C200_PAD,IRIVER_H100_PAD,IRIVER_H300_PAD%
                ,MPIO_HD200_PAD,MPIO_HD300_PAD}{\ButtonRec}%
            \opt{SANSA_FUZE_PAD,SANSA_CLIP_PAD}{\ButtonHome}%
            \opt{MROBE100_PAD}{\ButtonPower}%
            \opt{GIGABEAT_PAD}{\ButtonA}%
            \opt{GIGABEAT_S_PAD}{\ButtonPlay}%
            \opt{touchscreen}{\TouchTopRight}%
            \opt{PBELL_VIBE500_PAD}{\ButtonCancel}%
            \opt{SANSA_FUZEPLUS_PAD}{\ButtonBottomRight}%
            \opt{SAMSUNG_YH92X_PAD}{\ButtonFF{} + \ButtonUp}%
            \opt{SAMSUNG_YH820_PAD}{\ButtonRec{} + \ButtonUp}%
                &
            \opt{HAVEREMOTEKEYMAP}{
                &}
            Go to the next variation when at the first node in a branch
            \\
        }
    \end{btnmap}

\subsubsection{Menus}
\begin {description}
\item [Main Menu. ]
    The main menu for game setup and access to other menus.
    \begin{description}
        \item[New.] Create a new game with your choice of board size and handicaps.
        \item[Save.] Save the current state of the game.  It will be saved to
            \fname {/sgf/gbn\_def.sgf} unless otherwise set.
        \item[Save As.] Save to a specified file.
        \item[Game Info.] View and modify the metadata of the current game.
        \item[Playback Control.] Control the playback of the current playlist
            and modify the volume of your player.
        \item[Zoom Level.] Zoom in or out on the board.  If you set the zoom level,
            it will be saved and used again the next time you open this plugin.
        \item[Options.] Open the Options Menu.
        \item[Context Menu.] Open the Context Menu which allows you to set play
            modes and other tools.
        \item[Quit.] Leave the plugin.  Any unsaved changes are saved to
            \fname {/sgf/gbn\_def.sgf}.
    \end{description}
\item [Game Info. ]
    The menu for modifying game info (metadata) of the current game.  This
    information will be saved to the SGF file and can be viewed in almost all
    SGF readers.
    \begin{description}
        \item[Basic Info.] Shows a quick view of the basic game metadata, if any
            has been set (otherwise does nothing).  This option does not allow
            editing.
        \item[Time Limit.] The time limit of the current game.
        \item[Overtime.] The overtime settings of the current game.
        \item[Result.] The result of the current game. This text must follow the
            format specified at \url{http://www.red-bean.com/sgf/properties.html#RE}
            to be read by other SGF readers.  Some examples are
            \emph {B+R} (Black wins by resignation),
            \emph {B+5.5} (Black wins by 5.5 points),
            \emph {W+T} (White wins on Time).
        \item[Handicap.] The handicap of the current game.
        \item[Komi.] The komi of the current game (compensation to the white
            player for black having the first move).
        \item[Ruleset.] The name of the ruleset in use for this game.
            The \emph{NZ} and \emph{GOE} rulesets include suicide as a legal
            move (for multi-stone suicide only); the rest do not.
        \item[Black Player.] The name of the black player.
        \item[Black Rank.] Black's rank, in dan or kyu.
        \item[Black Team.] The name of black's team, if any.
        \item[White Player.] The name of the white player.
        \item[White Rank.]  White's rank, in dan or kyu.
        \item[White Team.] The name of white's team, if any.
        \item[Date.] The date that this game took place. This text must follow
            the format specified at \url{http://www.red-bean.com/sgf/properties.html#DT}
            to be read by other SGF readers.
        \item[Event.] The name of the event which this game was a part of, if any.
        \item[Place.] The place that this game took place.
        \item[Round.] If part of a tournament, the round number for this game.
        \item[Done.] Return to the previous menu.
    \end{description}

\item [Options. ]
    Customize the behavior of the plugin in certain ways.
    \begin{description}
        \item[Show Child Variations?] Enable this to mark child variations on
            he board if there are more than one.  Note: variations which don't
            start with a move are not visible in this way.
        \item[Disable Idle Poweroff?] Enable this if you do not want the \dap{}
            to turn off after a certain period of inactivity (depends on your
            global Rockbox settings).
        \item[Idle Autosave Time.] Set the amount of idle time to wait before
            automatically saving any unsaved changes.  These autosaves go to
            the file \fname {/sgf/gbn\_def.sgf} regardless of if you have
            loaded a game or used \setting{Save As} to save the game before or
            not.  Set to \setting{Off} to disable this functionality completely.
        \item[Automatically Show Comments?] If this is enabled and you navigate
            to a node containing game comments, they will automatically be
            displayed.
    \end{description}

\item [Context Menu. ]
    The menu for choosing different play modes and tools, adding or editing
    comments, adding pass moves, or switching between sibling variations.
    \begin{description}
        \item[Play Mode.] Play moves normally on the board. If there are child
            moves from the current node, this mode will let you follow
            variations by simply playing the first move in the sequence.
            Unless it is following a variation, this mode will not allow you to
            play illegal moves. This is the default mode before another is set
            after loading a game or creating a new one.
        \item[Add Black Mode.] Add black stones to the board as desired. These
            stones are not moves and do not perform captures or count as ko threats.
        \item[Add White Mode.] Add white stones to the board as desired. These
            stones are not moves and do not perform captures or count as ko threats.
        \item[Erase Stone Mode.] Remove stones from the board as desired. These
            removed stones are not counted as captured, they are simply removed.
        \item[Pass.] Play a single pass move.  This does not change the mode of
            play.
        \item[Next Variation.] If the game is at the first move in a variation,
            this will navigate to the next variation after the current one. This
            is the only way to reach variations which start with adding or
            removing stones, as you cannot follow them by ``playing'' the same move.
        \item[Force Play Mode.] The same as Play Mode except that this mode will
            allow you to play illegal moves such as retaking a ko immediately
            without a ko threat, suicide on rulesets which don't allow it
            (including single stone suicide), and playing a move where there
            is already a stone.
        \item[Mark Mode.] Add generic marks to the board, or remove them.
        \item[Circle Mode.] Add circle marks to the board, or remove them.
        \item[Square Mode.] Add square marks to the board, or remove them.
        \item[Triangle Mode.] Add triangle marks to the board, or remove them.
        \item[Label Mode.] Add one character labels to the board. Each label
            starts at the letter `a' and each subsequent application of a label
            will increment the letter.  To remove a label, click on it until it
            cycles through the allowed letters and disappears.
        \item[Add/Edit Comment.] Add or edit a comment at the current node.
        \item[Done.] Go back to the previous screen.
    \end{description}
\end{description}