Mike Follin is a former game developer who made ZX Spectrum conversions of games such as Bubble Bobble, Ghouls 'n Ghosts and The Sentinel. I got the opportunity to ask him some questions.
Q: Let's start with the Bubble Bobble conversion. What are your main memories for this project?
Bubble Bobble - happy memories! I’d done half-a-dozen games but never actually got paid. Then did The Sentinel for Software Creations, working from home. Bubble Bobble felt like my first proper job - it involved commuting in to Manchester City centre. Where we worked reasonable hours for a reasonable wage.
I remember printing out a listing later in the project and studying it on the train home. Come to think of it, we couldn’t have had many lines of code onscreen at once, and each line was just one instruction. So printing it gave a different perspective and helped to fix bugs.
Q: What was the hardest technical challenge? Do you remember any particular bug that was hard to fix?
The technical challenge was just to get so many sprites moving at once. I probably could have done it better by moving the main ones on interrupt-driven routines and leaving the bubbles to update when they could. (That’s how the C64 one worked.) The trouble on the Spectrum is having to erase and re-draw all the time. Failing to erase a piece of bubble here or there was probably the only bug I remember.
Not really a bug, but the two-player mode would never work properly (unless you had a kempston joystick) because each player could be pressing 3 keys at once - and the Spectrum can only handle 5.
It was great fun to work on because we had an arcade cabinet in the office, on free play of course. So Ste Ruddy and myself would play it though most days. Because that’s how we worked back then - no code was ever given to us from the original. We just played the game and wrote something from scratch that looked about the same.
Although Bubble was unique in that we did eventually get a few diagrams from Taito. I think they showed the enemy movement patterns (which we’d already figured out.) But the surprise was that every level had an ‘airflow’ map which the bubbles followed around the screen. We hadn’t allocated memory for that, so implementing it was a problem. That’s why I had to go with only 80 levels on the Spectrum. It was also why we were so tight on memory at the end that the first screen has my name on it but not Andrew Threlfall or Tim - highly embarrassing. I sent a demo off like that thinking I’d be able to fix it later when I’d found some memory, but later never came. That was the final version.
I think it was much simpler to do something like Bubble on the C64 because the hardware was a better match to the arcade game. But I also think Ste Ruddy was better than me at coding. He usually beat me on the arcade machine too! I used Ste’s idea for the airflow maps, which was to define a series of rectangles and set a direction in each one. A rectangle could be just 2 bytes I think.
Q: What development system did you use at this time? If you ran the game and it crashed, how long did it take to make a new build and try it?
The Tatung Einstein was used for source code (I think!) but I’d load data and graphics into a spectrum using a microdrive. Or at least that’s what I assume, given that Kev remembers me throwing one at a wall to get it working (surprisingly effective).
There was no debugging of course - if it crashed, it crashed. Generally I had coloured lines in the border and a rudimentary routine to print numbers on screen.
This seemed like luxury to me after developing on a single Spectrum where I’d have to reload everything from microdrive every time I tested the game. It would usually take several minutes to assemble a game - I think, but it’s quite hard to remember.
Q: The programming techniques used such as the raster avoidance and the sprite routines, did you come up with those yourself or were there a constant dialog/competition between colleagues where you gave each other advice?
There was very little discussion of programming. I was the only Z80 coder at Software Creations at first. No internet, just the odd magazine article for ideas. I think that’s where I picked up the idea of using the stack to speed things up. I read something while doing ‘Vectron’. That speeded things up so much that it was almost unplayable. In fact, ‘Vectron’ was more a tech demo than a game - I also did scrolling text as it loaded, and a full-screen loading picture extending into the border. And amazing music from Tim.
Other than the airflow suggestion from Ste, there was very little sharing techniques in those pre-internet days. It was my own idea to use the stack to read graphic data although I’m not the only one to have done that. Once you realize that the stack is fastest, you just use it wherever possible, as any decent coder did.
The raster-aware sprite thing was also my own idea. Perhaps because I’d just done ‘The Sentinel’, and it annoyed me that I couldn’t scroll the screen without raster tearing.
One bad idea I had with Bubble was to use the IX and IY registers to access the arrays of sprite information. Those instructions are so slow!
Q: You mentioned converting The Sentinel so lets talk about that. It is one of the most impressive and original games of the 8-bit era. Do you remember how you got that job? Did you already know the 3d-math required for this or did you have to learn that as you went along? How much contact did you have with Geoff Crammond during the process?
The Sentinel was extremely impressive and I can’t take any credit for it. All I did was put scrolling text in the border when it loaded, mostly so I didn’t interfere with what was onscreen. A guy called Peter Gough, who I worked with at Insight (on Vectron etc.) recommended me to Richard Kay (Mr. Software Creations). I think I went to Manchester with some sort of beat-em-up I was experimenting with, and he gave me a job. Which was to port The Sentinel from the Amstrad. (I don’t like the word ‘port’ - I reserve it for conversions where code can be reused. Bubble Bobble and most arcade conversions were complete writes from scratch.)
So we went to see Geoff Crammond with a guy from Firebird. I showed him a simple scroll routine to prove I could actually write code. I’d been given a BBC to play with, running Sentinel. I remember Geoff wearing a green army pullover with elbow patches. And he played guitar, so I told him his sentinel chord was C sharp minor 9th - which he didn’t know.
Geoff is a complete maths genius as well as a brilliant coder. I understand the basic principles of 3D - in fact there was a type-in Battlezone in a magazine with all the equations. I didn’t think that much math could be done in real time. Unlike Geoff, who originally thought that it would be possible to render The Sentinel in real time. So the gameplay actually evolved from the restrictions of the hardware. And turned out great of course!
Q: One of several fascinating facts of The Sentinel was the procedural level generation. Did this routine become identical on the ZX Spectrum so that the levels were the same as on C64?
The Sentinel used the same code on every format, so yes I expect the levels were the same. I got the Amstrad code to work from, so my job was to write shaders to turn the 4 colours into 4 patterns. (I disagreed with Geoff’s choice - I would have had ‘black’ and ‘white’ as the chessboard floor.) The sky was a separate routine drawing lines across the screen, using the stack of course. I did a lot of optimising the z80 code too, since it was generated by Geoff’s own 6502 to Z80 source converter.
So I didn’t have to know the inner workings of the code. Though I had a few hours on the phone to Geoff to tweak things.
Just in the last year it occurred to me that I should have done a 128k version of it.
Not to add more levels of course, but a 64k lookup table for the math would have speeded things up considerably.
Q: So Geoff Crammond made the Amstrad version himself using a custom built 6502 to Z80 translator?
Yes Geoff Crammond wrote a 6502 to Z80 converter for source code. Genius idea, but given the surplus of registers on the Z80, it’s actually quite straightforward. The downside is that the Z80 code is much slower than it could be. So I did much optimisation. I didn’t even have to know what the code was doing to make significant improvements.
Q: How does the "Vectron" loader work?
My Spectrum tape routine came about when I got a copy of the Spectrum ROM disassembly book. I saw that in the ROM routines there were delay loops. I wondered if it would be possible to use that time for something. So I developed code that replaced the delays with routines, split over several calls, to print half a character or scroll part of a line. (The downside was that it wasn’t smooth - speed depended on the bytes being loaded. ) Because I wrote the code to use exactly the same timing as the ROM, I could save something with the ROM code and load it back with ROM or my own code.
Q: Your brother Tim did music to several of your games. He created some of the most advanced multichannel music for the ZX Spectrum. How did that collaboration work, did he just send you the source of a finished piece of music or was he more involved than that? Did you learn any coding techniques from each other?
Tim learned Z80 coding from watching me working on the family colour TV. I told him how to speed things up with self-modifying code, which he then took to be the norm and did everything that way. He bought a ZX-81 first (couldn’t afford a Spectrum) and did some coding on that. I think I leant him my Spectrum at first. He bought a tiny synthesizer which helped him understand oscillators and envelopes and I suppose he basically encoded that. He went off and did his own thing - I don’t think we talked about code much once he knew how to do it. He just gave me a lump of code which made these amazing sounds.
Q: You've left the game development career. Was there anything specific that lead to that decision?
I had this thing I can only describe as a ‘spiritual experience’. These things are ultimately subjective and difficult to express. In as few words as possible: there was a moment one morning when I felt and understood that God is, and God is love.
So about 10 years after that, I applied for ordained ministry in the Church of England. Which I’ve now been doing for longer than I did programming.
I’m still interested in the philosophy of computing - and how this interacts with my faith.
For example, the philosopher Nick Bostrom got a lot of attention for saying that we could all be in a simulation. Take away the reliance on digital technology and you have exactly what religions have been telling us forever.
Q: Do you still have some work related documents and files from the 80s. If so, do you have any plans to digitally preserve those? Is there even a chance some source code can be publicly available?
I gave a stack of old disks to Kevin Edwards and he’s managed to retrieve code from most of them. I really don’t mind if people have access to that, although I’m a little concerned that I don’t own the copyright on them. I could make them available on a non-commercial basis I suppose!
Many thanks to Mike Follin for taking time to answer these questions!
Also see: ZX Spectrum Bubble Bobble graphics routines article.