_Games_
=======

The "Games" (Unix: plt/bin/games) executable is created by "Setup PLT"
(Unix: plt/bin/setup-plt). You can also start Games via Help Desk
(search for "games").

The Games program lets you select one of the games distributed by PLT,
or other games installed as sub-collections of the "games" collection
(see below).

 * _Same_ - The object is to score points by removing dots from the
   board. Click the "Help" button in Same for more details.

                                              - by Robby

 * _Go Fish_ (against two computer players) - The children's card game
   where you try to get rid of all you cards by forming pairs. The
   status line at the bottom of the window provides instructions as
   you go. [The computer players are not smart.]

                                              - by Matthew

 * _Blackjack_ - Standard rules, plus the following specifics:

      - 1 player (not counting the dealer)
      - 4 decks, reshuffled after 3/4 of the cards are used
      - Dealer stands on soft 17s
      - Splitting is allowed only on the first two cards, and only if
        they are equal; 10 and the face cards are all considered equal
        for splitting
      - Doubling is allowed on all unsplit hands, not on split hands
      - No blackjacks after splitting
      - No surrender
      - No insurance
      - No maximum under-21 hand size
      - Dealer's second card is not revealed if the player busts (or
        both halves of a split hand bust)

                                              - by Matthew

 * _Gin Rummy_ (against the computer) - Put all cards in your hand
   into straight and 3- or 4-of-a-kind sets to win. On each turn, you
   can either draw from the deck or from the discard pile, then you
   must discard one of your own cards. [The computer player is
   smart.]

                                              - by Matthew

 * _Minesweeper_ - A simple version of the classic tile-removing game.

                                              - by Matthew

 * _Paint by Number_ - A logic game. Click the "Help" button in Paint
   by Numbers for more details.

                                              - by Robby

 * _Lights Out_ - A color-toggling game. Click the "Help" button in
   Lights Out for more details.

                                              - by Robby

 * _Pousse_ - A game similar to tic-tac-toe, but tokens are pushed
   onto the board and can move other pieces. Click the "Help" button
   in Pousse for more details. You can install your own player
   programs. (This game was part of the 1998 ICFP programming
   contest.)

                                              - by Matthew


Implementing new Games
----------------------

The game-starting console inspects the sub-collections of the "games"
collection. If a sub-collection has an info.ss definition (see the mzc
manual) for `game', the result is used as a library name in the
sub-collection to load for the game. The library must export a
`game-unit' unsigned unit (see MzLib's `unit' form); the unit is
invoked with no imports to start the game. The `name' field of the
info.ss file is used to label the game-starting button in the game
console.

To implement card games, see the documentation for the "cards"
sub-collection of the "games" collection.
