User's guide

Snakes is a simple network game for one or more players. Game is runable on Linux and IRIX systems.

The game is played in the map (which is only empty square shaped place bounded by walls in this version). Each player has its own snake (only one unit long in this version) placed at a random position on the map at the begining of a game. A snake is drawn as a capital letter. Each player has his/her snake highlighted on his view of map. A snake has its actual direction and moves in this direction by default. The direction can be changed by pressing an arrow key. If a snake moves to the cell where the wall is then it crashes and the game is over for the player who played with this snake. Nevertheless, such player remains connected to the game to see how others are playing the game. The 'q' key quits the game whenever pressed.

There are names and actual scores of players written in the right part of screen. There is also the letter which represents the player's snake stated here in front of each player's name or the '#' character if the player's snake is already dead or '*' if player has been disconneted from the server.

There is exactly one cell in the map which contains food (drawn as '@' character) in any time. The goal is to take this food, i.e. to move your snake to the cell where it is placed. Than you get one point. Player who has the most points wins the game.

The game is controlled by the server process. You have to run the server process before running any client. Server is started with default settings by the "snakes -s" command. If you want to change a port where it listens to clients, game name or player count, you can specify options as it is described when you run "snakes -h".

Each game is associated with exactly one server. You can run any number of games you want by running more servers.

After the server has been started you can start client(s). Run "snakes -c". Client sends UDP broadcast to address 255.255.255.255 by default (you can change it by option "-b") and displays responses from all servers, i.e. the list of available games. You should choose one of displayed game and enter your snake's name. The name have to be unique in the scope of the game. If you specify the name which is already in use you are asked for the another one. After entering unique name you are joined the game and you have to wait until other players are joined. Than the game starts.

Server can be shut down by pressing Ctrl+C or other key combination which invoke the SIGINT signal.