1	GALAXY
A Multi-User Star Trek game for VT100, VT52, ADDS or ADM-3A terminals.

2 Playing

     The game is very similar to the  traditional  Star-Trek
game   with  the  following  exceptions.   First,  the  game
involves several players (1-8), each of  whom  has  his  own
terminal  and  starship.  Second, the game runs in real time
as far as the players are concerned.  For  example,  if  you
are  going  warp  8  you will continue to move regardless of
your activity at the terminal (unless you are destroyed, hit
something,  run  out  of energy, or change your warp speed).
Each player's status and position as well as the  scores  of
all  players  is  displayed and continuously updated at each
player's terminal.  (The update rate is  twice  per  second,
but  the  source  code  is  commented  on where to change it
should you wish to do so.) Third, at the present time  there
are no Klingons or Romulans to shoot down, instead you shoot
(or at least attempt to shoot) the other players.

     The universe consists of a  100  by  100  matrix  which
wraps  around  itself.  Therefore if you move off one end of
the universe you appear on the other end.  (This is true  of
phasers and torpedoes also.)

The universe is made up of the following items:

     1.  " "      Empty space

     2.  "-"      Universe boundary

     3.  "*"      Star

     4.  "B"      Star-base (ram  it  to  dock  and  thereby
         refuel)

     5.  "H"      Hyperspace point (described below)

     6.  "R"      Random hyperspace  point  (also  described
         below)

     7.  "+"      Torpedo

     8.  "^"      Homing torpedo (seeker)

     9.  "#"      Black hole will pursue nearest player

    10.  "@"      Anti-matter pod

    11.  "%"      Energy net

    12.  "1"-"8"  Player's ships

3 Hyperspace Ports

     When a hyperspace port is hit by a  ship  the  ship  is
teleported  to a new location in the universe.  The "H" type
of hyperspace port can be used  to  go  to  a  set  location
whereas  the  "R"  type of port produces a random jump.  The
"H" ports are located at  fixed  locations;   these  are  as
follows:
                 PORT NUMBER    X COORD    Y COORD
                 -----------    -------    -------

                      1            20         75
                      2            50         70
                      3            80         75
                      4            20         25
                      5            50         30
                      6            80         25
 
 
THE NETWORK OF PORTS LOOKS LIKE THIS:
 
                 1                                    3
                                   2
  
 
     
 
                                   5
                 4                                    6
 

     By using the "H" command a  player  can  set  the  port
number he wishes to appear beside the next time he goes into
hyperspace through an "H" type  port.   For  example,  if  a
player used the "H" command to set his hyperspace setting to
 4, the next time he ran  into  an  "H"  character  he  would
appear near coordinates 20,25.

     A  player's  anti-matter   pod   can   travel   through
hyper-space  also;   upon  re-emergence  in the universe, it
blows up.  Pods going  through  random  hyperspace  reappear
randomly;   those  going  through "H" type ports reappear at
the pod owner's current hyperspace jump point.



2 Scoring

     The current scores of all players are displayed on  the
screen.   A  '*'  beside a score indicates an active player.
The following actions result in score changes:

     1.  Torpedo hit on enemy vessel:     +500



     2.  Homer hit on enemy vessel:       +300

     3.  Phaser hit on enemy vessel:      +(between  70  and
				         200 depending on distance)

     4.  Pod explosion:                   +(between 300  and
				         1500 depending on distance)

     5.  Torpedo hit on base:             -200

     6.  Getting destroyed:               -1000






3 Energy Consumption


     1.  Shooting phasers:  -50

     2.  Warp:              -.5  *  WARP  SPEED   per   time
			         interval

     3.  Send message:      -10

     4.  Collide with star: -200

     5.  Collide with ship: -100

     6.  Cloaking:          -25 per time interval (default)

     7.  Energy net:        -75  per  net  unit  constructed
			         (default)

     8.  Tractor beam:      -200 per time interval (default)


     Energy loss due to weapon hit is a function  of  shield
strength and weapon energy.



3 Calculations


The following formula are used:

     1.  Phaser hit energy:

             ENERGY=900./(4. + DISTANCE)


     2.  Torpedo hit energy:

             ENERGY=500.

     3.  Shield protection:

             SHIELD ABSORBTION FACTOR=SHIELD ENERGY/1000.
                 (WITH A MAXIMUM VALUE OF 1.)
             SHIELD DIRECTION FACTOR=
                  (.5 + ABS(SHIP'S DIREC - WEAPON'S DIREC)/360)
             SHIELD FACTOR = SHIELD DIRECTION FACTOR *
                                  SHIELD ABSORBTION FACTOR
          
             SHIELD ENERGY =
                  SHIELD ENERGY - SHIELD FACTOR * ENERGY OF HIT
             ENERGY OF SHIP = ENERGY OF SHIP -
                  (1.2 - SHIELD FACTOR) * ENERGY OF HIT * 6

     4.  Tractor beam pull:

             8./SQRT(MAX(1., DISTANCE BETWEEN SHIPS-6.))


     Anti-matter causes both damage to the scan, and results
in  an  energy  hit.   Both  of  these  effects  are  energy
dependent.



2 Commands

     All commands consist of one character, and most of them
require a numeric argument.  This argument can be input with
the  command  character,  or  can  be  a  default  ship   or
direction.  Generally, typing a new ship number or direction
changes the default ship or  direction,  however  there  are
exceptions.   In addition, the "L" (long range scan) command
changes the  default  direction  to  the  direction  of  the
scanned  ship, which is convenient for firing at the scanned
ship.   See  below  for  other  commands  which  change  the
defaults.   To  use  a  default  value, simply type carriage
return.  If you wait more than a few seconds before typing a
numeric  argument  or  <CR>,  you  will  be prompted for the
argument, however you needn't wait for the  prompt  to  give
the argument.

     1.  Help
             "?"    Prints a summary of all commands.

     2.  Shields
             "S"    Raise or lower  shields.   You  will  be
                    prompted  for  a  real  number (+ or -).
                    Your  default  shield  change  value  is
                    reset   every   time  you  set  positive
                    shields, and this default value  may  be
                    used  by  typing  a  <CR>  after the "S"
                    command.  1000 units is  the  most  that
                    will  do  any  good; but you may want a
                    little reserve.

     3.  Reset
             "R"    Clears the screen and redraws the entire
                    display.

     4.  Torpedoes
             "T"    Fire torpedoes.  You  will  be  prompted
                    for  a  direction.   <CR>  fires  in the
                    default direction,  a  number  fires  in
                    that  direction  and resets the default.
                    Torpedoes move at warp 10,  and  destroy
                    anti-matter pods.

     5.  Phasers
             "P"    Fire phasers.  You will be prompted  for
                    a  direction.  <CR> fires in the default
                    direction,  A  number  fires   in   that
                    direction   and   resets   the  default.
                    Phasers are instantaneous, have a  range
                    of  10  squares,  and  shoot  a  band  3
                    squares wide.   They  will  not  destroy
                    torpedoes (except homers).

     6.  Locate
             "L"    Long range scan for another player.  The
                    "L"  command  sets the default direction
                    to that of the scanned ship.  It takes a
                    ship  number  as an argument, or <CR> to
                    locate the  default  ship.   If  a  ship
                    number  is  given,  the  default ship is
                    reset to that ship.

     7.  Message
             "M"    Send a  message  to  another  player  on
                    subspace   radio.   <CR>  sends  to  the
                    default ship, a  ship  number  sends  to
                    that   ship.   A  ship  number  of  zero
                    broadcasts the  message  to  all  ships.
                    The default ship is not reset.

     8.  Warp
             "W"    Set warp speed 0-8.

     9.  Course
             "C"    Set course 0-12 (clock face).  This does
                    not  affect  your  warp speed or default
                    direction.    However,    the    default
                    direction may be used to set the course.
                    All directions are to  be  specified  in
                    "clock face" numbers.  For example:
                        


                                         0. IS UP
                     
                              9. IS LEFT           3. IS RIGHT
                     
                                         6. IS DOWN
                     
                    7.5 is toward  the  lower  left  corner,
                    etc.

    10.  Quit
             "Q"    Quit.

    11.  Hyperspace
             "H"    Set hyperspace jump point 1 through 6.

    12.  Cloak on
             "F"    Fade away.  The  cloaking  device  is  a
                    continuous energy drain when activated.

    13.  Cloak off
             "A"    Appear.

    14.  Energy net on/off
             "E"    Start/stop  energy   net   construction.
                    Energy nets provide a "wall" which other
                    ships will bounce off of,  however  your
                    ship   travels  instantaneously  through
                    your energy nets.  Torpedoes may be used
                    to  destroy  nets.   The  black  hole is
                    blocked  by  them.    Phasers   do   not
                    penetrate nets.
		    Nets disappear when their creator dies.

    15.  Homing torpedo launch
             "K"    You will be prompted for the ship number
                    to  home  in  on.   <CR> homes in on the
                    default ship, a ship number homes in  on
                    that   ship   and  resets  the  default.
                    Homing  torpedoes  destroy   anti-matter
                    pods.   Homing  torpedoes  can  be shot
                    down with phasers (at least sometimes).
		    Homing torpedoes become static mines when
		    their mothership gets destroyed.
		    Homing torpedoes move at Warp 10.

    16.  Anti-matter launch
             "Z"    You will be prompted  for  a  direction.
                    Pods  move at warp 5.  <CR> fires in the
                    default direction,  a  number  fires  in
                    that  direction  and resets the default.
                    When   an   anti-matter   pod   hits   a
                    hyper-space  port, it travels through it
                    to your current  hyperspace  jump  point
                    and  blows up.  Pods also travel through
                    random hyper-space  ports  to  a  random
                    location and blow up.


    17.  Anti-matter freeze
             "N"    Stop  movement  of  anti-matter  device.
                    (It will become a static mine.)

    18.  Anti-matter detonate
             "X"    Detonate   anti   matter   pod.     This
                    explosion   destroys   an  entire  area,
                    except for bases and hyperspace  points.
                    The  pattern  of  the  explosion  is  as
                    below.
                     
                                            X 
                                        X   X   X 
                                          X X X
                                      X X X X X X X 
                                          X X X 
                                        X   X   X
                                            X
                     
                    Ships within 4 of an exploding pod  lose
                    some   energy   and  have  their  vision
                    partially obscured.  The black  hole  is
                    randomly  relocated when caught in a pod
                    explosion.
		    Pods are also capable of destroying stars.

    19.  Tractor beams
             "B"    Set tractor beam target ship  (1-8).   0
                    to stop tractor beam.  Tractor beams are
                    used  to  pull  your   opponent's   ship
                    towards  you.   The closer the ships are
                    the stronger the  pull  of  the  tractor
                    beam.  The default ship is reset.

    20.  Verbose/Non-verbose mode
             "V"    Flip   on/off    verbose    mode.     In
                    non-verbose  mode, only the first letter
                    of each word is printed.  For example,

                         + TORPEDO HIT ALIEN!

                    becomes

                         +THA

                    This is sometimes useful in the heat  of
                    battle on a slow (1200 baud) terminal.

	Note that since TYPEAHEAD is supported under VMS, it is
	possible to get a lot of commands in the type-ahead buffer
	in the heat of a battle.  Remember that control-X will
	clear the type-ahead buffer and allow you to alter your
	course, etc. in an emergency!!


2 Starting the Game

	The GALAXY Manager will decide on the default Universe
	parameters for your particular site based on the values
	below:


     Initialization parameters can be set to those values listed
     below:

     1.  A star density between 2 and 3 is good  (default  =
         2.0).

     2.  About 20 to 25 star-bases is ok (default = 20).

     3.  Usually 5-10 random jump points (default = 6).

     4.  Any random integer between -32k and +32k (default =
         3214).

     5.  A cloaking energy drain of 20 to 40 (default = 25).

     6.  Net construction energy drain of 0 to 2000 (default
         = 75).

     7.  Black hole speed of 2.  to 5.  (default = 3).

     8.  A Tractor Beam drain of 0. to 2000.  (default = 100).



3 Player Initiation

Several crt terminals are required to  play  the  game.

Your terminal must be one of the supported types of
CRT terminals:	VT52	VT100	ADM-3A	ADDS-520/580

You must set your terminal characteristics to match
with one of the following VMS commands:

	SET TERMINAL/VT52	SET TERMINAL/VT100
	SET TERMINAL/FT1 (foreign type 1 is for ADM-3A)
	SET TERMINAL/FT2 (foreign type 2 is for ADDS-520/580)

Note:
Special effects have been added as a bonus to those players
who have VT100 type terminals.
You will miss a lot of the action if you don't play on a
VT100 type terminal.

Each player should issue the following command at his
terminal:

     $ RUN GALAXY

GALAXY will only allow play during pre-defined hours of the
day (values that can be specified by, you guessed it, the
GALAXY Manager).

A list of unoccupied ships will be displayed, so  choose  an
unoccupied  ship  and you are ready to play.  It is possible
for two  or  more  players  to  control  the  same  ship  by
selecting  an  occupied  ship,  e.g., one player can control
navigation and the other weapons.   Players  may  enter  and
leave the game at any time.



2 Robot Ships

     In addition to playing against human opponents you  can
turn  the  unused  ships  over to computer control.  This is
done by starting the ROBOT  program.   You  can  choose  the
ships  to  be  controlled  and  the capability of the ships'
robot skippers.

     Each running ROBOT program can  control  several  ships
which will act as a team.  If more than one ROBOT program is
started then their ships will fight with each other.   Robot
ships are started with the command:

	$ RUN ROBOT
	(Note: Robot ships may or may not be available for
	       general use.  Consult your GALAXY Manager.)

A list of unoccupied ships will  be  displayed.   Enter  the
number(s)  of  the  ship(s) to be under robot control.  When
the robot "team" has been selected, enter <CR> and the ROBOT
program  will ask several questions to set up the ability of
the robot skippers.

     1.  Maximum speed of robot ships (default = warp 8).

     2.  Robot reaction time (default = 1.5).

     3.  Amount of phaser fire (default = 5).

     4.  Degree of inaccuracy (default = 0 degrees).

Note that while the ROBOT program is running, the issuing
terminal will be controlled by the ROBOT(s) and therefore
not useable for play.  Please use another crt terminal for
the session or submit the program in a BATCH stream.


2 Terminating the Game

     It is important that the last GALAXY  players  clean  up
the  system  before they leave.  This is done by following the
simple rule:

     1.  Terminate each GALAXY program by  entering  the  "Q"
         command.

Now mop up the blood, sweat, and  tears;   logout;   and  go
home.
