|
The following article was printed in March 1989 of the magazine „8000 PLUS".
|
|
RACER
by A Conforth and M Anson
|
Anyone who owned a computer in the early days of the home computer boom (something like five years ago!) will remember the various race games based on a scrolling screen and a static character that can be moved from side to side.
This game has been on every machine ever made that boasted a scrolling screen.
Like Pacman it remains a classic, impossible to see without wanting to have a go.
This version boasts five levels of difficulty and can keep track of high scores (all right, just one more go, but even if you don't make five hundred it's still bedtime).
Once loaded the game requires a single keypress to start whereupon the road begins to roll down the screen and your car appears (well, the letter C which at least stands for car).
The keys Z and X are used to move the car to the right and left to stop it crashing into the barriers down the side of the road.
Once you finish (or more likely crash) the score is displayed and if it's the highest for the session you are invited to enter your name.
There are several improvements that could be made to the game, for example a high score table for each skill level can be added and perhaps saved to disc so that it is available each time the game is played.
Another possibility would be to redefine the characters used by the game to improve the appearance.
A leisurely perusal of the Pacman upgrade by Joseph Walton could help with that.
Making the game more difficult could be accomplished by narrowing the road at random intervals.
|
|
The lines up to 70 initialise the game, setting up the Functions used later and the inevitable (but necessary) cls$.
The OPTION RUN command disables the [stop] key and since Basic doesn't have to check for it this allows the program to run a little faster
|
|
|
|
The lines from 80 to 200 allow you to choose the level of difficulty to play at.
Note that lines 130 to 170 could have been replaced with an ON number GOTO line which would have looked tidier.
|
|
|
|
Various things are going on here and it looks a bit confusing.
In general putting the variables in one place makes things easier to understand.
For fastest operation they should all have gone at the end since Basic has to look through lines from the beginning each time it finds a GOTO or GOSUB.
For the same reason often used GOSUBs should be at the beginning for greater speed.
|
|
|
|
Checking for a hit is very lime consuming when the only way to do it is to keep track of the screen position and value of the various characters.
We're hoping to publish a machine code listing to do this very soon.
|
|
|
|
Notice that this is a well behaved game.
It switches the status line back on when you quit.
Always try to leave things tidy.
[BASIC listing] |
|
HTML customization by
Werner Cirsovius
February 2015
© 8000 PLUS