HOME COMPUTING WEEKLY, 6 September 1983, page 36
SPECTRUM PROGRAM

Prepare for battle -- the enemy subs are on their way  seek out and
destroy the hostile fleet - those are your orders in Peter Telfer's
exciting game for the 48k Spectrum.

You are in command of a nuclear  submarine, cruising the Mediterranean
on routine patrol. Suddenly a message comes through from base:"Enemy
Fleet sighted  at vector 14/13 in Sector Stigma. Preparing to launch
attack on Horne Base. Your mission - to seek out and destroy the enemy.
Message ends." You immediately set a course for Sector Stigma and
prepare for battle.

HOW IT WORKS
  10		set up colour for instructions
  20-30		set up title
  90-94		display title character by character BEEPing between
		each character
 100		set up UDGs from DATA on lines 9000-9020
 110		set up auto-scroll
 120-140	print instructions
Graphics:  140  A,CD,EFG,HIJK
 160-200	set up position of enemy ships
Graphics:  170	HI-JK,176EFG,182CD,188A
 355-440	input of X,Y co-ordinates
1000-1020	check if hit,miss
1030-1100	display hit ship, increase score.
Graphics:  1050	H,I,J,K
2000-2020	give up routine
2100		display positions of enemy ships
2520		win routine (if all ships are hit),
		display score with bonus
3000-3100	replay routine
9000-9020	data for UDG

On arrival, you switch on your targeting computer showing the grid of
the enemy zone. Your job is to locate and destroy all of the enemy's 20 ships.

Main variables
Z$	Battleships title
A$	position of enemy ship
B$ 	input of X,Y co-ordinates
X	  down co-ordinates of target computer
Y	across co-ordinates of target computer
End	end of game routine
S	score
AMO	ammunition
Hit	number of hits on ships
Point	score for particular hit
A + B	FOR...NEXT loops

Hints on conversion
 The POKE on line 100 switches the Spectrum to auto-scroll. If your
computer doesn't have this feature, then the screen could be displayed
by having a pause/wait followed by CLS between each page.
 The POKE in line 320 switches the CAPS-lock on (upper case letter).
 The input of the X,Y, coordinates works using ASCII code of the letter
pressed(ie. the letter A = 65, the letter B = 66 and so on). If the
character code of your computer is different then alter the (-64) in
line 370 and 410 to suit your computer.
 PAPER X where x is the background colour of a character square.
 INK x where x is the colour of the character.
 BORDER x where x is the border.
 Spectrum colour codes:
 0 black, 1 blue, 2 red, 3 magenta, 4 green, 5 cyan, 6 yellow, 7 white
 FLASH 1(on line 1070) alternates PAPER and INK colours.





























