home *** CD-ROM | disk | FTP | other *** search
- **************************************
-
- PERISCOPE
-
- **************************************
-
-
- By: Herman M. Stevenson, Jr.
-
-
-
- It's back!! The old time "shoot the
-
- ships out of the water" game. And
-
- guess what? It's written without
-
- sprites. You can enjoy the game
-
- and/or use it as an example of the
-
- techniques used. Some of us are
-
- traditionalist, although we may use
-
- "up to date" programing tools, it's
-
- sometimes nice to reminisce and do it
-
- the old way. Well, Periscope proves
-
- that you can design a program that is
-
- fun to play using traditional
-
- programming methods.
-
-
- Instructions for the game are
-
- included in the program, but an
-
- overview is given below.
-
-
- First you are prompted - 'Do you
-
- need instuctions? (y/n).' Answer yes
-
- and you are told...
-
- The object of this game is to
- sink as many boats as you can
- with your 12 torpedos. To do
- it, you fire them from your sub
- using 1 of the 6 tubes...
-
- The tubes are marked one through
-
- six. Tubes two and five fire at 30
-
- degree angles from the bow of the
-
- sub. Tube two fires 30 degrees to the
-
- left and five to the right.
-
-
- Press any key to view the next
-
- instruction page which tells you that
-
- you get one bonus if you make over
-
- 500 points. The bonus is an
-
- additional 6 torpedos and 12 more
-
- boats. Next, you are shown the
-
- various types of boats with their
-
- point values.
-
-
- To start the game, it is necessary
-
- that you enter the speed that you
-
- desire. You can choose from one to
-
- nine. Nine is the slowest, giving you
-
- 16 boats. One is the fastest, so you
-
- get 24 boats.
-
-
- Enter your choice and start your
-
- mission.
-
-
-
- If you desire to learn or review the
-
- program structure, below are some
-
- interesting points:
-
-
- Line Explaination
- ==== ============
-
- 5 In the print statement,
- there is a reversed "H".
- This is the same as
- chr$(8) which puts the
- keyboard in graphic mode.
-
- 10 Pokes in the sound for voice
- number one.
-
- 15 Pokes in the sound for voice
- number two.
-
- 35 Randomly selects the order
- of the boats that sail
- across the screen.
-
- 40 Checks to see when the score
- goes over 500 to give you
- your bonus torpedoes.
-
- 50 Works in conjunction with
- line 40. It stops you from
- getting more than one
- bonus.
-
- 55 Makes sure line 35 only
- selects up to six boats.
-
- 60 Sets the limits on the
- length of the game.
-
- 65-
- 70 Print the score at the
- bottom of the screen.
-
- 100-
- 665 Print the six boats at the
- top of the screen.
-
- 900-
- 925 Checks to see if a torpedo
- is in motion.
-
- 2000-
- 4650 Print out each of the six
- torpedo paths as
- selected by the GET
- statment.
-
-
- 10070 The reversed "I" in the
- print statement,
- equivalent to CHR$(9),
- resets the graphic shift
- key.
-
-
-
- Notice in line 35, where the random
-
- generator selects the next boat. The
-
- generator selects from one to ten
-
- boats, although there are only six
-
- boats to choose from. This attribute
-
- causes a very small delay in time so
-
- that a no-miss firing pattern is
-
- changed. This stops someone from just
-
- pushing a number to sink a boat every
-
- few seconds.
-
- ------
-
- This program is copyrighted by
-
- PowerPlay magazine. All rights to it
-
- are reserved. LOADSTAR has relieved
-
- you from the burden of keying in this
-
- program. For more complete
-
- information about this program, refer
-
- to the January 1986 issue of PowerPlay
-
- Magazine.
-
- --------------------------------------
-