Man Linux: Main Page and Category List

NAME

       xtris - multiplayer tetris for X

SYNOPSIS

       xtris  [  -display  machine:0  ] [ -help ] [ -k keys ] [ -s ] [ -bw ] [
       -big ] [ -flashy ] [ -n  name  ]  [  -norestart  ]  [  -nospeedup  ]  [
       server.name [ port ] ]

OPTIONS

       -bw    With  this  option, the game will be drawn in black & white even
              on a color display.

       -big   Makes xtris use larger graphics.

       -display
              Specify the X display where xtris will open a window to play the
              game.   By  default,  xtris connects to the display specified in
              the environment variable DISPLAY.

       -flashy
              Selects an alternate, flashier set  of  colors  for  the  tetris
              bricks.

       -help  Prints   out   a  summary  of  the  command-line  options  xtris
              recognizes.

       -k     Redefine the keys  used  by  xtris.   The  argument  must  be  a
              6-letter  string  with  the  keys to move to the left border, to
              move one position to the left, to rotate, to move  one  position
              to the right, to move to the right border and to drop the brick,
              respectively.  The default keys are ’JjklL.

       -n     Sets the nickname for the player.  The max nickname length is 14
              characters.

       -norestart
              Passes  the  ’-norestart’ option to xtserv if xtris can’t find a
              server running and starts one of its own.  This has  the  effect
              of  telling the server not to automatically restart a game after
              everyone save one player has lost.

       -nospeedup
              Passes the ’-nospeedup’ option to xtserv if xtris can’t  find  a
              server  running  and starts one of its own.  This has the effect
              of telling the server not to  automatically  increase  the  game
              speed.

       -s     Starts  the  game  in standalone mode.  In this mode, xtris will
              not connect to a server, will not be able to interact with other
              players, and will not be able to start bots.

ARGUMENTS

       server.name
              Specifies  the  machine  on which an xtris server (xtserv) runs.
              xtris will connect to that server, and add itself to the game.

              If the server is not specified, xtris will attempt to connect to
              a  server  on localhost (127.0.0.1).  If no server is running on
              localhost, xtris will start one (with the ’-once’ option  so  it
              will not stay after the client exits).

       port   Specifies the port to connect to, if the server was started on a
              port other than the default (19503).

DESCRIPTION

       xtris is version of the classical game of  Tetris  for  any  number  of
       players, under the X window system.

       Multi-player  games  are  managed by the xtris server, xtserv; they are
       synchronous: all users play at the same level, start at the same  time,
       and  see  each  other’s  games.   The  game  stops when only one player
       remains.

       xtris keeps track of the number of lines each player has filled in  the
       current game, and of the number of games each player has won.

       Each  player  has  a  name,  initially  set  to  his login name, or the
       contents of the environment variables XTRISNAME or NETTRISNAME.

       Whenever there is more than one player, players can  type  messages  to
       each  other,  which  appear on a special message area; players who have
       already lost can chat this way while the game continues.

       To edit your name, move the mouse pointer to the small  window  at  the
       bottom of the screen where it is displayed.  The editing keys backspace
       and ^U are recognized, as well as iso-latin-1 characters  entered  with
       the  help  of the Meta (mod1) key.  Pressing Return propagates the name
       to all other players.

       There are two modes for the game:

       normal The game starts with an empty pit.  Whenever one user fills  two
              or  more rows at the same time, these lines appear at the bottom
              of some other user’s screen.

              At the beginning of the game, each player is  set  to  send  his
              lines  to  the  next  player,  in the order of connection to the
              server.  After sending some lines, the  server  chooses  a  next
              victim for the player, sequentially.

       fun    The  game starts with some garbage at the bottom and the side of
              the pit.  Whenever one player fills a line, his victim  gets  an
              extra gray square at the highest point of his game.  Filling two
              lines simultaneously sends one line; filling three sends  three,
              and filling four sends five.

MESSAGES

       The  message  area is a zone under the tetris pits where users can chat
       by typing messages at each other.  It is not displayed by  default;  to
       activate it, click on the "text" button, which appears as soon as there
       are two or more users.

       If verbose mode is activated, the message zone also gets messages about
       the  development  of the game, users changing nicks, starting the game,
       sending each other lines, and so on.

       When you put your mouse pointer in the message area, the text you  type
       goes  to  the  input  line  at the very bottom of the window.  When you
       press Return, your line gets sent to all other players.

       If you hold down the Shift key when  pressing  Return  in  the  message
       area,  the  mouse pointer gets warped back to the main game.  This lets
       you type in a message quickly during the game: press Tab to warp to the
       message area, and end your message with Shift-Return to warp back.

BOTS

       Bots, or robots, are automated players that connect to the xtris server
       and simulate a game of Tetris.  Clicking on the ’bot’ button will start
       a  bot  and  connect it to the same game.  It is also possible to start
       bots from the command line, with xtbot.

       To remove a bot from the game, click on its name at the bottom  of  the
       window.

KEYS AND BUTTONS

       These keys can be redefined with the -k option or with X resources:

       Key        Resource           Action

       J          leftBorderKey      Move to the left border.
       j          leftKey            Move one position to the left.
       k          rotateKey          Counter-clockwise rotation.
       l          rightKey           Move one position to the right.
       L          rightBorderKey     Move to the right border.
       ,          downKey            Move down one step.
       Space      dropKey            Drop the brick.

       Alternatively,  you can use the arrow keys to move the piece around one
       step, and the shifted arrow keys  to  move  it  all  the  way  in  each
       direction.  The Up arrow key rotates.

       These keys can be redefined only with X resources:

       Key        Resource           Action.

       s          startKey           Start a game.
       q          quitKey            Quit the game.
       p          pauseKey           Pause/continue the game.
       b          botKey             Start a bot on the same server.
       n          modeKey            Change  the  game mode between normal and
                                     fun.
       t          textKey            Open/close the message area.
       Return     toggleNextKey      Toggle display of the next brick.
       c          clearKey           Clear the message area.
       v          verboseKey         Toggle  displaying  of  server   messages
                                     about the game in the message area.
       z          zeroKey            Reset the game counters to 0.
       Tab        warpKey            Warp  the  mouse pointer between the game
                                     area,  the  nick  entry  area,  and   the
                                     message area (if visible).
       0 - 9      (no resource)      Set the level.

       The buttons on the xtris screen are:

       Start               Start  a game (all players start at the same time).
       Quit                Quit the game.
       Pause               Pause or continue the game.
       Bot                 Start a bot on the same server.
       0 - 9               Set the level.
       Normal              Toggle normal and fun game mode.
       Text                Display or hide the message area.
       Zero                Reset the game counters to 0.
       Verbose             Toggle displaying of server messages about the game
                           in the message area.
       Clear               Clear the message area.

       Clicking  on  the  area  where the Next brick is displayed also toggles
       displaying the Next.

RESOURCES

       xtris understands a number of X resources. The prefix for all  of  them
       is ’xtris.’.

       In  addition  to the ones listed in the KEYS section, xtris understands
       these resources:

       name           Specifies the player’s nickname.   The  default  is  the
                      login name.

       big            Specifies  whether  xtris  should use larger graphics or
                      not.  The default is ‘‘false’’.

       flashy         Specifies whether xtris should use  flashier  colors  or
                      not.  The default is ‘‘false’’.

       bw             Specifies whether xtris should start up in black & white
                      mode.  The default is ‘‘false’’.

       verbose        Specifies whether xtris should start up in verbose mode.
                      The default is ‘‘false’’.

       scrollLines    Specifies  the size (in lines) of the message area.  The
                      default is 10, and the allowed values are from 3 to  30.

       background     Specifies the color used for the background.

       brick0
       ...
       brick6         Specifies the color used for the i-th brick.

ENVIRONMENT

       The  environment  variable  DISPLAY  controls  the default X display on
       which to open the xtris window.

       The environment variables XTRISNAME and NETTRISNAME  set  the  player’s
       initial name.

EXAMPLE

       The command

              xtris -k ’Kkl;: ’ -bw esane.net -display dedelamnio:0

       starts an xtris on the display dedelamnio:0, connected to the server on
       esane.net, with the keys K, k, l, ;, : and  space,  and  in  black  and
       white.

SEE ALSO

       xtserv(6), xtbot(6)

BUGS

       The default colors are rather hideous.

       Please report any other bugs to the author.

AUTHOR

       xtris was written by Roger Espel Llima <roger.espel.llima@pobox.com>.

       Some bits of X11 code are based on xtet42 by Hugo Eide Gunnarsen of the
       Norwegian Institute of Technology.