games: Massive style(9) cleanup commit. Reduces differences to NetBSD.
[dragonfly.git] / games / snake / snake / snake.6
1 .\" Copyright (c) 1980, 1993
2 .\"     The Regents of the University of California.  All rights reserved.
3 .\"
4 .\" Redistribution and use in source and binary forms, with or without
5 .\" modification, are permitted provided that the following conditions
6 .\" are met:
7 .\" 1. Redistributions of source code must retain the above copyright
8 .\"    notice, this list of conditions and the following disclaimer.
9 .\" 2. Redistributions in binary form must reproduce the above copyright
10 .\"    notice, this list of conditions and the following disclaimer in the
11 .\"    documentation and/or other materials provided with the distribution.
12 .\" 3. Neither the name of the University nor the names of its contributors
13 .\"    may be used to endorse or promote products derived from this software
14 .\"    without specific prior written permission.
15 .\"
16 .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
17 .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
18 .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
19 .\" ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
20 .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
21 .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
22 .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
23 .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
24 .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
25 .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
26 .\" SUCH DAMAGE.
27 .\"
28 .\"     @(#)snake.6     8.1 (Berkeley) 5/31/93
29 .\" $FreeBSD: src/games/snake/snake/snake.6,v 1.4.2.1 2001/07/22 11:01:23 dd Exp $
30 .\" $DragonFly: src/games/snake/snake/snake.6,v 1.5 2007/10/20 17:56:47 swildner Exp $
31 .\"
32 .Dd May 31, 1993
33 .Dt SNAKE 6
34 .Os
35 .Sh NAME
36 .Nm snake ,
37 .Nm snscore
38 .Nd display chase game
39 .Sh SYNOPSIS
40 .Nm
41 .Op Fl w Ar width
42 .Op Fl l Ar length
43 .Op Fl t
44 .br
45 .Nm snscore
46 .Sh DESCRIPTION
47 .Nm Snake
48 is a display-based game which must be played on a CRT terminal.
49 The object of the game is to make as much money as possible without
50 getting eaten by the snake.
51 The
52 .Fl l
53 and
54 .Fl w
55 options allow you to specify the length and width of the field.
56 By default the entire screen is used.
57 The
58 .Fl t
59 option makes the game assume you are on a slow terminal.
60 .Pp
61 You are represented on the screen by an I.
62 The snake is 6 squares long and is represented by s's with an S at its head.
63 The money is $, and an exit is #.
64 Your score is posted in the upper left hand corner.
65 .Pp
66 You can move around using the same conventions as
67 .Xr vi 1 ,
68 the
69 .Ic h ,
70 .Ic j ,
71 .Ic k ,
72 and
73 .Ic l
74 keys work, as do the arrow keys.
75 Other possibilities include:
76 .Bl -tag -width indent
77 .It Ic sefc
78 These keys are like hjkl but form a directed pad around the d key.
79 .It Ic HJKL
80 These keys move you all the way in the indicated direction to the
81 same row or column as the money.
82 This does
83 .Em not
84 let you jump away from the snake, but rather saves you from having
85 to type a key repeatedly.
86 The snake still gets all his turns.
87 .It Ic SEFC
88 Likewise for the upper case versions on the left.
89 .It Ic ATPB
90 These keys move you to the four edges of the screen.
91 Their position on the keyboard is the mnemonic, e.g.,
92 P is at the far right of the keyboard.
93 .It Ic x
94 This lets you quit the game at any time.
95 .It Ic p
96 Points in a direction you might want to go.
97 .It Ic w
98 Space warp to get out of tight squeezes, at a price.
99 .El
100 .Pp
101 To earn money, move to the same square the money is on.
102 A new $ will appear when you earn the current one.
103 As you get richer, the snake gets hungrier.
104 To leave the game, move to the exit (#).
105 .Pp
106 A record is kept of the personal best score of each player.
107 Scores are only counted if you leave at the exit,
108 getting eaten by the snake is worth nothing.
109 .Pp
110 As in pinball, matching the last digit of your score to the number
111 which appears after the game is worth a bonus.
112 .Pp
113 To see who wastes time playing
114 .Nm ,
115 run
116 .Nm snscore .
117 .Sh FILES
118 .Bl -tag -width ".Pa /var/games/snakerawscores" -compact
119 .It Pa /var/games/snakerawscores
120 database of personal bests
121 .It Pa /var/games/snake.log
122 log of games played
123 .El
124 .Sh BUGS
125 When playing on a small screen,
126 it's hard to tell when you hit the edge of the screen.
127 .Pp
128 The scoring function takes into account the size of the screen.
129 A perfect function to do this equitably has not been devised.