Treasure Hunter

Hand-drawn map of Treasure Island with Hangman's Hill, Highest peak, Treasure grove and Hope Cove
Hand-drawn map of Treasure Island with Hangman's Hill, Highest peak, Treasure grove and Hope Cove

TREASURE HUNTER is a clever little game in which a hunter, denoted by an asterisk, has to find treasure which is hidden at a random position on the screen. The only assistance given to the hunter is that he is told when he is getting warmer.

It can be very annoying when, whichever way you move, you seem to be getting warmer but cannot find the exact location of the treasure. When the correct spot is found, the number of steps taken is shown on the screen, along with the program’s idea of the optimum number.

The first attempt by the Timex Sinclair User’s reviewer resulted in 453 steps taken against an optimum of five. That later improved to 84 against an optimum of 30.

The hunter is moved by using the cursor keys but an added difficulty is that if you go to the edge of the screen you bounce back so that the left and right keys and the up and down keys become reversed.

Treasure Hunter was sent by P. Brown.

  10 REM TREASURE HUNT BY P AND A BROWN
20 LET P=PI/PI
30 LET Q=PI-PI
40 LET L=INT (RND*VAL "15")+VAL "2"
50 LET C=INT (RND*VAL "27")+VAL "2"
60 LET S=Q
70 LET OP=P
80 LET OQ=Q
90 LET P=P+(INKEY$="6")-(INKEY$="7")
100 LET Q=Q+(INKEY$="8")-(INKEY$="5")
110 CLS
120 PRINT AT P,Q;"*"
130 LET S=S+PI/PI
140 IF P=L AND Q=C THEN GOTO VAL "210"
150 LET D=L-P
160 LET E=C-Q
170 LET F=L-OP
180 LET G=C-OQ
190 IF ABS D+ABS E<ABS F+ABS G THEN PRINT AT 0,0;"WARMER"
200 GOTO VAL "70"
210 PRINT AT L,C;"X"
220 PRINT "LOOT FOUND IN";S;"STEPS"
230 PRINT "OPTIMUM";L+C-VAL "1"

Note: Type-in program listings on this website use ZMAKEBAS notation for graphics characters.