[3074] in comp.os.os2.announce archive
GAME: Battleship game with source code
daemon@ATHENA.MIT.EDU (David Boudah)
Sat Jun 21 23:07:38 1997
To: os2ann.DISCUSS@bloom-picayune.MIT.EDU
Date: 21 Jun 1997 18:04:00 -0400
From: dboudah@ibm.net (David Boudah)
Reply-To: dboudah@ibm.net (David Boudah)
Reply-to: dboudah@ibm.net (David Boudah)
[Followups directed to comp.os.os2.games]
---------------------------------------------------------------------
SOFTWARE OS/2 Battleship Game v1.0 with Source code Available now
I have submitted an OS/2 version of the board game BATTLESHIP to the
Compuserve OS/2 Developers 1 and VACPP forums. The archive is called
BATTLE.ZIP.
This game was developed using OS/2 Visual C++ compiler and the OpenClass class
libraries.
The original game is played on two separate plastic frames, each of which has
a horizontal and a vertical playing surface. The horizontal surface is used
for both defensive ship placement and the marking of each of your opponents
shots with white pegs to register a "miss" and red pegs to register a "hit".
The vertical surface is used for your offensive shots against your opponent.
Each player's fleet consists of 5 ships: aircraft carrier, destroyer,
battleship, submarine, and a PT boat. Each player distributes their fleet
randomly around the horizontal surface. A player then takes a "shot" by
specifying a row and column location (i.e. a letter and number combination -
A1 to J10). The opponent then responds with "hit" or "miss" appropriately.
When all the targets on a given ship are hit, the ship is considered sunk.
The player that sinks his opponent's entire fleet is the winner.
In this implementation, the left board is the human player's board and the
right is the computer's. Each board consists of 100 individual squares in a
10-by-10 matrix.
Sound is provided via the OS/2 multimedia classes. You will notice that
different sounds are played when different actions occur in the game. Some
examples are firing at a ship, ships sinking, mines getting hit, and the end
of the game.
The game is released as shareware and I hope you will enjoy it.
_____________________________________________________________________
| POST to COOA to submit [alternative mailto:comp-os-os2-announce@uunet.uu.net]
| Correspondence to the COOA Moderator: mailto:lfirrantello@bix.com .
| Please see: http://www.bix.com/pub/os2ann/pindex.htm for posting guidelines