SINCLAIR PROGRAMS, May 1984
===========================


CAR PARK
--------
AFTER FINISHING your night shift you go to the car park and start your car,
only to discover the brakes have been sabotaged. There is no way for you to
stop the car so you head for the exit, trying to keep control of the vehicle.
You reach the exit gates and find they have been locked. The only alternative
is to drive round and round the car park, avoiding the parked cars and
barriers. Car Park was written for the 16K Spectrum by David McAuliffe, aged
14, of London SE18.


**********************************************************************


CHIP RAID
---------
THE OBJECT of the game is to stop the bugs descending onto the microchip. You
control the protector, which is located just above the microchip, using keys
"1" and "2" for left and right and "0" to fire. Position yourself below the
bug as it runs down the wire and shoot it. If more than three bugs land they
drain all your energy and the game ends. Chip Raid was written for the 16K
Spectrum by Peter Beard of London SE23.


**********************************************************************


ESCAPE (aka. Convict)
------
YOU HAVE just escaped from prison and are making your way to your hideout. On
the way you must collect as many jewels as possible while avoiding the
numerous policemen in pursuit. As the game progresses the border colour
changes and at the end your score is given. Ten points are gained for each
jewel collected. Convict is compatible with the Kempston joystick or can be
played using keys 5 and 8. Written for the 16K Spectrum by Tim Wreford, aged
13, of Windsor, Berkshire.


**********************************************************************


HARRIET DODGES THE SPIDERS for Sinclair Spectrum
by Alan Rees
from Sinclair Programs, May 1984

Harriet Dodges the Spiders was written for the 16K Spectrum by Alan
Rees, aged 13, of Abergavenny, Gwent. The object is to dodge the
oncoming spiders to stay alive for as long as possible. You gain a
bonus serum every 1,000 points. The game is joystick-compatible with
the ZX Interface Two. If you have no Interface Two, you can use keys 1
and 2 to move left and right.


**********************************************************************


PSEUDO LOGO
Sinclair Programs, May 1984


PSEUDO LOGO was written for the48K Spectrum by Duncan Anderson of
Bishops Frome, Worcester. He called the program Pseudo Logo because it is
similar to the programming language Logo, which uses an arrow.

Imagine that you are the arrow so that you can input the correct
commands for left and right. The player is faced with a square grid and must
program the moves of the arrow so that it reaches the blue and magenta target
without going off the grid or running into any of the red obstacles.

The three commands for determining the direction of the arrow are the initial
letters for left, right and forward. When programmed to turn, the arrow rotates
45 degrees. The program is of particular use to young children, as they have
to program the moves of the arrow and the process of doing so develops their
geometrical and mathematical thinking.

Logo is programming language which allows the user - usually a child - to
move a turtle about the screen or on the floor. Not a real turtle - it is
normally a small triangle as far as the screen is concerned, or a small robot
which can be controlled from the micro.

Simple commands such as FORWARD, BACKWARD, LEFT and
RIGHT are used to control the direction of the turtle and it is possible to
build complex patterns in a very short time.

Pseudo Logo incorporates some of the features of the Logo language, insofar
as it uses commands to move an arrow about the screen. The author has
incorporated it into a game and the result is something which is worth the
time and effort of entering into a Spectrum.

The program is loaded in the normal manner for a Basic program by entering
LOAD "" or LOAD "Pseudologo". After running it, a menu will appear
offering the choice of three speeds for the arrow - slow, medium and fast.
Once the speed has been selected a 32-by-16-line square grid will appear and
in each alternate square is a dot. Also displayed will be some red irregular-
shaped blocks and a yellow arrow, as well as a small blue square.

The object of the game is to have the arrow touch the blue square and when
that is done you will be moved into another grid where the red blocks are
more frequent, thus making the path to the blue square more difficult to
navigate.

You have to write a small program to move the arrow. The commands are
simple and there are only three of them: F, L and R; for forward, left and
right respectively.

One point to note is that you can turn in any of eight directions, so to move
the arrow five squares forward and three to my left I would enter
FFFFFLLFFF. Notice that left is given twice, because once turns the arrow
only 45 degrees, thus allowing you to travel at an angle.

Ten grids make up the game and your thinking efficiency is displayed at
the end, together with the number of moves you made.

The program is divided roughly into the following main sections:
140-170		What direction?
230		Run out of program.
2000-2010	Completed one grid.
2015-2020	Win and score.
2500		Crashed into red block.
9010-9110	Define UDGs and read block data.

Here is a list of the main variables and their functions:
c	Grid counter and index for I$.
d	Direction of arrow, e.g., 1 = north, 2 = north-east.
n	General-purpose counter.
sx	Row number of arrow.
sy	Column number of arrow.
ex	Row number of arrow.
ey	Column number of arrow.
b$	Holds red block data for current grid.
x	Loop counter in block display, also x pos for arrow.
y	Loop counter in block display, also y pos for arrow.
p$	Holds user's program.
i$	Key pressed.
tot	Total number of program steps.
p	Number of program steps in current rty, also index.
ox	Current row number of arrow.
oy	Current column number of arrow.
m	Pitch of beep.
n	Pitch of beep.
per	Percent thinking efficiency.
mp	Constant for per.
w$	Temporary store for INKEY$.
spd	Speed of arrow.
l$()	Holds data for blocks, arrow and blue square.

The best way to handle the program is to enter all the data first and then save
it on to tape. Be very careful with the data for b$ - the lettered data - it
contains all the information on the arrow, square, blocks and so on - so
check.

The data in lines 9040-9110 is read into the array l$, which is dimensioned
at line 9040. The data looks confusing at first but closer examination reveals
that the first number is the starting direction for the arrow, the next four
numbers are the row and column for the arrow, and after that the next four are
the same but for the blue block. The values are given to variables at lines 30-50.

The rest of the data is fed into string b$. Eight numbers are extracted from
it and used in loops which print out the red blocks - line 50.

The screen is displayed in line 20 and the program prompt in line 60. A check
is made to see if the current character is satisfactory and, if so, it is
added to p$ which holds the current program - line 100.

The author has decided to make some decisions using AND; also note the use
of IF ... THEN IF. I will be discussing those techniques in next month's
programming feature on making decisions.

Traditional turtles in Logo leave a track behind them and that is used to
make up a pattern. If you wish, you can have a trail by removing the square
graphics in lines 210, 2000 and 2700. Another idea would be to create your
own blocks by changing the appropriate data.


**********************************************************************


SPACE RACE
----------
YOU ARE a lone crusader travelling through the galaxies in your rocket. You
are faced with several hazards along the way which you must dodge, including
the stars and space phantoms. You can ride on the moon bases to gain extra
points but do not land for too long or you will be carried away. There are 30
skill levels from which to choose. Use "1" to move right and "0" to move
left. Space Race was written for the 16K Spectrum by E Marsden of Upper
Denby, West Yorks.


**********************************************************************


TANK BATTLE
-----------
YOU ARE in control of the tank on the left-hand side of the screen. Invade
enemy territory to win the battle, using the cursor keys to move. The enemy
tank can fire at you but you cannot return the fire. You cannot hide behind
the cacti and must move quickly to avoid the fire of the opposing tank to
reach the other side. Tank Battle was written for the 16K Spectrum by Michael
Pasmore, of Addlestone, Surrey.


**********************************************************************


TRAP
----
USE the Kempston joystick to move around the screen in Trap, written for the
16K Spectrum by Paul Johnson, aged 13, of Newton-le-Willows, Merseyside. As
you move, holes you must try to avoid appear. Falling down a hole will mean
instant death. If you are trapped by holes on all four sides you can press
"9" to escape. The holes are often flashed on the screen before they appear,
so you know which areas to avoid. You must eat the seeds and plants as they
appear.


**********************************************************************


WOLF ATTACK
-----------
You are the leader of your village and must protect the villagers from a pack
of ravenous wolves. The wolves head towards the village from the woods and
you must intercept and kill them with your axe to prevent them reaching the
village. If they reach the village they will eat the occupants until there
are no more villagers. Use the Kempston joystick to move. Wolf Attack was
written for the 16K Spectrum by P Hodges of Ashford, Kent.


**********************************************************************


