xref: /dragonfly/games/snake/snake/snake.6 (revision f2c43266)
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
48is a display-based game which must be played on a CRT terminal.
49The object of the game is to make as much money as possible without
50getting eaten by the snake.
51The
52.Fl l
53and
54.Fl w
55options allow you to specify the length and width of the field.
56By default the entire screen is used.
57The
58.Fl t
59option makes the game assume you are on a slow terminal.
60.Pp
61You are represented on the screen by an I.
62The snake is 6 squares long and is represented by s's with an S at its head.
63The money is $, and an exit is #.
64Your score is posted in the upper left hand corner.
65.Pp
66You can move around using the same conventions as
67.Xr vi 1 ,
68the
69.Ic h ,
70.Ic j ,
71.Ic k ,
72and
73.Ic l
74keys work, as do the arrow keys.
75Other possibilities include:
76.Bl -tag -width indent
77.It Ic sefc
78These keys are like hjkl but form a directed pad around the d key.
79.It Ic HJKL
80These keys move you all the way in the indicated direction to the
81same row or column as the money.
82This does
83.Em not
84let you jump away from the snake, but rather saves you from having
85to type a key repeatedly.
86The snake still gets all his turns.
87.It Ic SEFC
88Likewise for the upper case versions on the left.
89.It Ic ATPB
90These keys move you to the four edges of the screen.
91Their position on the keyboard is the mnemonic, e.g.,
92P is at the far right of the keyboard.
93.It Ic x
94This lets you quit the game at any time.
95.It Ic p
96Points in a direction you might want to go.
97.It Ic w
98Space warp to get out of tight squeezes, at a price.
99.El
100.Pp
101To earn money, move to the same square the money is on.
102A new $ will appear when you earn the current one.
103As you get richer, the snake gets hungrier.
104To leave the game, move to the exit (#).
105.Pp
106A record is kept of the personal best score of each player.
107Scores are only counted if you leave at the exit,
108getting eaten by the snake is worth nothing.
109.Pp
110As in pinball, matching the last digit of your score to the number
111which appears after the game is worth a bonus.
112.Pp
113To see who wastes time playing
114.Nm ,
115run
116.Nm snscore .
117.Sh FILES
118.Bl -tag -width ".Pa /var/games/snakerawscores" -compact
119.It Pa /var/games/snakerawscores
120database of personal bests
121.It Pa /var/games/snake.log
122log of games played
123.El
124.Sh BUGS
125When playing on a small screen,
126it's hard to tell when you hit the edge of the screen.
127.Pp
128The scoring function takes into account the size of the screen.
129A perfect function to do this equitably has not been devised.
130