Yep, there's a story.
Before Moon Patrol, I already had written some other small games, that used user-defined characters.
I found out about UDG's in the type-in listings of programs in computer magazines, like "CPU", "Compute mit", and "RUN" (the last of which should also be known in non-German countries).
As I already said, I didn't know about the cartridge port of Moon Patrol by Atari Soft, released in 1983. Games for the VIC were already hard to come by in 1986, with the C64 taking over the market. I knew the arcade version very well, and
I simply wanted to play it on the VIC.
In the spring of 1986 I stumbled upon multi-colour characters. One thing, that practically never had been used in those type-ins I knew of. Multiple colours within
one char, a revelation to me! But at first I had a hard time finding out how to define them correctly. Colour 0 - obviously - was the same as the background, colour 1 incidentally was the same as the exterior border colour, colour 2 was defined by the low 3 bits of colour RAM, but colour 3 somehow always remained - black. I tried writing in various registers of VIC, but only after I lend out a reference manual from a friend I saw, that colour 3 was defined by the
upper 4 bits of the volume register.
Before that, I wrote a test-game named "HELI RESCUE", where you had to fly through a labyrinth cavern, to rescue a person trapped in the cavern. The frame of the helicopter was red, its screen windows cyan, the rotor was black. But for a game with black background, colour 3 needed to be changed, and now I had the solution.
Freshly equipped with that knowledge about colour 3, I began designing the graphics for Moon Patrol, on squared paper, then transferring it to DATA lines. Normally, one would reserve the last 512 bytes of BASIC memory - I would only need 24 chars, so I just reserved 256 bytes, still with room for 8 additional characters. Aside: the SPACE character was located quite at the beginning of my UDG's. And there's also the reverse character trick, which accesses the normal character set.
I developed the main program on the screen editor, and there were seldom more than 6 lines of the program visible on screen. That lead to the task of designing a prototype with few lines, which would then be expanded by using a knapsack (now we enter the dark caverns ...)
At first I wrote the joystick read routine, together with a scrolling routine for the ground. That one was done with the 'MID$(...,2)+Char' trick, printing out the resulting string always at the same place. Then I added the parallax scrolling mountains in the background.
The addition of craters, and the meteor (which was moved with POKE) required a collision detection, a jump routine for the buggy, score display, and a effect-routine for the explosion (if you didn't react).
Then came the UFO. It would only fly in a straight line over the screen, so the only danger (for both opponents) were rockets, shot up, and down. In 1986 I weren't able to combine this into the rest of the program properly, so the game stopped while shooting the rockets. Which made it mainly luck, which side would strike first. I completed the game with the ending sequence, where the buggy happily reaches the Moon base, and decorated the sky with stars.
I copied the game on tape for some friends, but I doubt these copies survived.
In September 1986 I got a C128, so I did little more with the VIC. Also, the PSU of the VIC fried, and I put the VIC dormant for 9 years in the desk. During that time, Moon Patrol hibernated on a tape as well.
(... enter the light at the end of the cavern):
In the summer of 1995, I found another working VIC on the flea market. I had thought all the time, that my first VIC was broken. Just for fun I also tried the new PSU with the first VIC, and it worked! A good friend of mine reminded me of Moon Patrol, so I did the following: I started up my then current computer (an Acorn Archimedes A5000), the VIC, and loaded in Moon Patrol. Then every line of the two parts (character definition, and main program) was transferred by eye, and keyboard to the A5000. But I needed to switch off thinking about what I was copying here.
Because, when I had done the transfer, I made a close inspection - and was about right: This had been the worst spaghetti code one could imagine!
Seeing this mess, I sat down on the A5000, and tore the program to pieces. With a good text editor on my hands, I identified the small pieces that made all the effects, and restructured them to a new implementation, aiming at moving
everything simultanously.
Here's the result.