1\input texinfo   @c -*-texinfo-*-
2@c $Id: moon-buggy.texi,v 1.15 2003/02/18 10:41:37 voss Exp $
3@c %**start of header
4@setfilename moon-buggy.info
5@settitle Moon-Buggy Usage and Maintenance
6@include version.texi
7@c %**end of header
8
9@dircategory Games
10@direntry
11* moon-buggy: (moon-buggy).     Drive some car across the moon
12@end direntry
13
14@ifinfo
15This file documents moon-buggy, a simple character graphics game.
16
17Copyright 1999, 2000 Jochen Vo@ss{}
18
19Permission is granted to make and distribute verbatim copies of this
20manual provided the copyright notice and this permission notice are
21preserved on all copies.
22
23@ignore
24Permission is granted to process this file through TeX and print the
25results, provided the printed document carries a copying permission
26notice identical to this one except for the removal of this paragraph
27(this paragraph not being relevant to the printed manual).
28
29@end ignore
30Permission is granted to copy and distribute modified versions of this
31manual under the conditions for verbatim copying, provided that the
32entire resulting derived work is distributed under the terms of a
33permission notice identical to this one.
34
35Permission is granted to copy and distribute translations of this
36manual into another language, under the above conditions for modified
37versions, except that this permission notice may be stated in a
38translation approved by the Free Software Foundation.
39@end ifinfo
40
41@setchapternewpage off
42@titlepage
43@title Moon-Buggy Usage and Maintenance
44@subtitle @value{UPDATED}
45@subtitle Edition @value{EDITION}
46@sp 8
47@center @image{title,,}
48@author by Jochen Vo@ss{}
49
50@page
51@vskip 0pt plus 1filll
52Copyright @copyright{} 1999, 2000 Jochen Vo@ss{}
53
54Published by Jochen Vo@ss{}
55
56Permission is granted to make and distribute verbatim copies of this
57manual provided the copyright notice and this permission notice are
58preserved on all copies.
59
60Permission is granted to copy and distribute modified versions of this
61manual under the conditions for verbatim copying, provided also that the
62entire resulting derived work is distributed under the terms of a
63permission notice identical to this one.
64
65Permission is granted to copy and distribute translations of this manual
66into another language, under the above conditions for modified versions,
67except that this permission notice may be stated in a translation
68approved by the Free Software Foundation.
69@end titlepage
70@headings double
71
72@node Top, Introduction, (dir), (dir)
73
74@ifinfo
75Moon-buggy is a simple character graphics game, where you drive some
76kind of car across the moon's surface.  Unfortunately there are
77dangerous craters there.  Fortunately your car can jump over them!
78
79This edition (last updated @value{UPDATED}) of the manual applies to
80version @value{VERSION} of the program.
81@end ifinfo
82
83@menu
84* Introduction::                Introduction
85* Moon-buggy Invocation::       Moon-buggy Invocation
86* Playing the Game::            Keyboard commands
87* Shared Score Files::          Competition via the highscore table
88* Installation::                Installation and setup
89* References::                  References
90@end menu
91
92
93@node Introduction, Moon-buggy Invocation, Top, Top
94@chapter Introduction
95
96Moon-buggy is a simple character graphics game, where you drive some
97kind of car across the moon's surface.  Unfortunately there are
98dangerous craters there.  Fortunately your car can jump over them!
99
100Moon-Buggy comes with no warranty, to the extent permitted by law.  You
101may redistribute copies of Moon-Buggy under the terms of the GNU General
102Public License.  For more information about these matters, read the file
103@file{COPYING} of the source code distribution or press @key{c} at
104moon-buggy's title screen.
105
106Please mail any suggestions and bug reports to
107@email{voss@@seehuhn.de}.  Your message should include the
108moon-buggy version number, as obtained by the command @samp{moon-buggy -V}.
109
110New versions of Moon-buggy may be found on the sunsite ftp server or on
111the moon-buggy download page (@pxref{References}).
112
113
114@node  Moon-buggy Invocation, Playing the Game, Introduction, Top
115@chapter Moon-buggy Invocation
116
117Normal usage is to start @samp{moon-buggy} without any options.
118Nevertheless there are some.  The long options (starting with @samp{--})
119are only supported on some system types.
120
121@table @samp
122@item -h
123@itemx --help
124shows a short usage message.
125
126@item -m
127@itemx --mesg
128disable write access to your terminal by other users,
129so your boss can't disturb your game play with the help
130of "write" or "finger".
131
132@item -n
133@itemx --no-title
134skips the title screen.
135
136@item -s
137@itemx --show-scores
138shows the current highscore list and exits.
139
140@item -V
141@itemx --version
142prints the program's version to standard output and exits.
143@end table
144
145
146@node Playing the Game, Shared Score Files, Moon-buggy Invocation, Top
147@chapter Playing the Game
148
149The game is controlled by a couple of keys, which are described near the
150bottom of the screen.  Most important are the following keys.
151
152@table @key
153@item SPC
154@itemx j
155makes your car jump.  The length of a jump is fixed and you can only
156start a new jump while the wheels have contact to the ground.
157@item a
158@itemx l
159fires the mining laser.  The laser is used to remove stones, which may
160block your way.
161@item q
162quits the game prematurely.  But you still keep your score and may enter
163the highscore list.
164@end table
165
166Moon-buggy can handle a wide range of screen sizes.  But it runs best
167if the screen has at least 80 columns.  If you run it on a screen with
168significantly less columns it may look strange and could be hard to
169play.
170
171
172@node Shared Score Files, Installation, Playing the Game, Top
173@chapter Shared Score Files
174
175Moon-buggy has two concepts of score files: the @dfn{global score file}
176is located somewhere in the installation directories and is shared
177between all players.  The exact place in the file system can be
178controlled via @code{configure}'s @samp{--sharedstatedir} option.  This
179highscore file is used whenever Moon-buggy has the permissions to access it.
180Otherwise the @dfn{local score file} is used.  This file is located in
181the user's home directory, the file name is @file{.mbscore}.  Thus, the
182local score file is not shared between different accounts.
183
184As the game is much more fun, when players can compete for the highest
185scores, the global score file should be writable for the moon-buggy
186program (but not for the user's text editor).  Here is a list of
187possible policies:
188
189@enumerate
190@item
191The preferred solution is to make moon-buggy a setgid program.  This
192means the following: you choose a group ID, which cannot be used by
193ordinary users, and allow only members of this group to write the score
194file.  Many systems have a group @samp{games} for this purpose (Check
195your @file{/etc/group} file).  You make this group own the
196@file{moon-buggy} executable and set the file's setgid bit.  This bit
197gives moon-buggy its file groups's access permissions and so the program
198is able to access the score file.
199
200You can use @code{configure}'s @samp{--with-setgid} option
201(@pxref{Installation}) to properly set up access permissions for this model.
202
203@item
204You could make moon-buggy a setuid program but for security reasons this
205is not recommended.  The file @file{SECURITY} from the bsd-games
206distribution (@pxref{References}) has some informations about this
207topic.
208
209@item
210Another solution is to make the score file world writable.  But then you
211have to trust your players: every player may open the score file with
212his favourite text editor and change it freely.  So this is not
213recommended, too.
214
215@item
216Finally you could do nothing.  Then every account uses its local score
217file.
218@end enumerate
219
220
221@node Installation, References, Shared Score Files, Top
222@chapter Installation
223
224Moon-buggy requires the curses library as a prerequisite.  If curses is
225not installed on your system, you may use the free ncurses package
226(@pxref{References}).  The game does not work with BSD curses, thus on
227BSD systems you will need the ncurses package.
228
229When you unpack the moon-buggy distribution, you get one directory,
230which holds all the source files and the documentation.  Generic
231installation instructions are in the file @file{INSTALL}.  There are
232some points of interest:
233
234@itemize @bullet
235@item
236By default, the program will be installed as
237@file{/usr/local/bin/moon-buggy}.  You can specify an installation
238prefix other than @file{/usr/local} by giving @samp{configure} the
239@samp{--prefix=@var{path}} option.
240
241@item
242You can choose the score file's location via @code{configure}'s
243@samp{--sharedstatedir=@var{dir}} option.  The score file then will be
244@file{@var{dir}/moonbuggy/mbscore}.  On GNU/Linux systems you should use
245
246@example
247--sharedstatedir=/var/games
248@end example
249
250@noindent
251to comply with the Filesystem Hierarchy Standard (@pxref{References}).
252
253@item
254Moon-buggy supports shared score files.  For details, see @ref{Shared
255Score Files}.  As explained there, you may want to make moon-buggy a
256setgid program.  This can be done with the @samp{--with-setgid} option.
257If you use
258
259@example
260--with-setgid=games
261@end example
262
263@noindent
264then the installation process arranges everything for setgid usage.
265
266@strong{Caution}: this introduces potential security risks.  I tried to
267minimise these, but nevertheless be careful with this.  And remember:
268moon-buggy comes with no warranty.
269
270@item
271If your version of the curses library is not autodetected, you have to
272use some of the @samp{--with-curses-includedir},
273@samp{--with-curses-header}, and @samp{--with-curses-libs} options.  For
274example you should use
275
276@example
277--with-curses-includedir=/usr/pkg/include
278@end example
279
280@noindent
281if your curses header files are in @file{/usr/pkg/include/}.
282You may use
283
284@example
285--with-curses-header="<mycurses.h>"
286@end example
287
288@noindent
289if your curses header is called @file{mycurses.h}.  And you may use
290
291@example
292--with-curses-libs="-L/usr/pkg/lib -lncurses"
293@end example
294
295@noindent
296if your curses library is called @file{ncurses.a} and is located in
297@file{/usr/pkg/lib/}.
298@end itemize
299
300
301Example: On GNU/Linux systems you probably can use the following
302commands.  For the last one you need root user permissions.
303
304@example
305./configure --sharedstatedir=/var/games --with-setgid=games
306make
307make install
308@end example
309
310
311@node References,  , Installation, Top
312@chapter References
313
314This chapter gives some references to resources mentioned in the manual.
315As the internet changes incessantly, the addresses below may be
316outdated.  If you find this to happen, please report it as a bug.
317
318The latest version of @strong{Moon-buggy} may be found on the sunsite
319archive in the directory
320@url{ftp://sunsite.unc.edu/pub/linux/games/arcade/}.
321
322I provide a @strong{moon-buggy download page}, which is located at
323@url{http://seehuhn.de/comp/moon-buggy.html}.
324
325Version 2.0 of the @strong{Filesystem Hierarchy Standard} (FHS 2.0) may
326be found on the internet at
327@url{ftp://sunsite.unc.edu/pub/linux/docs/fhs/fhs-2.0.tar.gz}.
328
329The @strong{ncurses} package can be found on the GNU project's ftp
330server and its mirrors.  The original site is
331@url{ftp://prep.ai.mit.edu/pub/gnu/ncurses/ncurses-4.2.tar.gz}.
332
333Hints about @strong{security concerns} may be found in the file
334@file{SECURITY} from the bsd-games package.  One location where to find
335it is @url{ftp://sunsite.unc.edu/pub/linux/games/bsd-games-2.7.tar.gz}.
336@bye
337