MUNCHIE AND THE HOONOS
from Home Computing Weekly, 11th October 1983

Munch for your life

If you like running around mazes eating fruit, you'll love
Alan Jarvis' Munchie game for any Spectrum.


You are the Munchie trapped in a maze with two evil Hoonos. Escape is
impossible - your only aim is to survive.

The Munchie is moved around the maze using the cursor keys (5 to 8). The
Hoonos are carnivorous, so they must be avoided - unless you can make your
way to a power-star, which when eaten will give you power over the Hoonos so
you can eat them for a bonus of 500 points. But be warned! The effects of a
power star don't last long.

Once the dots below the Hoonos' den are eaten, fruit will start appearing at
this position and these can be munched for bonus points (100 points for pears
and apples, 200 for cherries and 300 for lemons). The Hoonos also drop
dynamite at random as the maze clears, so avoid this or you will lose a life.
Doors at each side of the maze will transport you to the other side.

It would probably be best to enter and run the first 24 lines before entering
the rest of the program. The first eight lines restore the normal character
set, then lines 9-15 poke the hi-res graphics onto the lower case letters.
All variables should be entered as upper case letters, or else the listing
will look strange. All characters within PRINT statements or in the DATA at
the end of the program should not be entered in graphics mode, but should be
entered as standard lower-case letters.

Lines 19-24 POKE three machine code noises on to the graphics characters.
Great care should be taken in entering the DATA; one wrong item could crash
the system. To test the noises, type: RANDOMIZE USR USR "A", RANDOMIZE USR
USR "E", RANDOMIZE USR USR "I".


How it works
   2-8     resets character set
   9-15    POKEs graphics onto lower-case letters
  19-24    POKEs machine code noises onto graphic characters
  30-98    variables
 100-148   set up screen
 204       check to see if maze is cleared
 205-225   move Munchie
 230-244   check if Munchie is eating apple, star, etc.
 280-285   move Munchie through doors
 310-325   move ghosts
 400       prints a score graphic when a fruit is munched
 500-525   print fruit below ghosts' den
 600-620   ghosts drop dynamite
1000       Munchie sinks in quicksand
1100-1115  ghost dies
5000-5015  end of game
9000-9020  maze DATA


Variables
hi      hi-score
sc      score
l       lives left
game    the number of sheets started
l$      shows number of lives left (graphically)
e$      ghost one graphic
g$      ghost two graphic
a$      closed mouth Munchie
b$      opened mouth Munchie
bon     bonus points
p       check whether Munchie has power to eat ghosts or not
z       loop while the effects of a power star last
f$      holds fruit graphics
i$      holds ink colours relative to each fruit
r       random element to make fruit appear, etc.
x,y     horizontal and vertical co-ordinates of Munchie
x1,y1   horizontal and vertical co-ordinates of ghost one
x2,y2   horizontal and vertical co-ordinates of ghost two
f       how many times fruit has appeared
c$      array holding maze
j$      title string
z$      holds score graphic when fruit is eaten


Hints on conversion
Lines 2-11 will only work on the Spectrum, so someone with a different
computer would have to replace these with lines which will create the
graphics on their machine. (There arc 23 graphic characters in this program.)
  Lines 20-24 can omitted and when there is a RANDOMIZE USR USR in the
program this should be changed to a sound command.
  The way the Spectrum handles strings is slightly "sub-standard", so LEFT$s,
etc. will have to be used to print out the fruits from F$, etc.
  The colours of the game are as follows: munchie - yellow, ghosts - green
and magenta, or blue when a power pill has been eaten. The background colours
are black and the maze is cyan.
  The I$ might cause a few problems, for it holds the INK numbers relative to
each fruit in F$ - 4 (green) for apples and pears, 2 (red) for cherries and
6 (yellow) for lemons.
  Converting will be difficult, but I'm sure it will prove to be a challenge
to the more experienced programmer.
