I’ve been playing around with the 6809 microprocessor for a while now. It was used in the Dragon 32/64 computer and Vectrex console. It is an easy and fun architecture to program for (I am an ardent believer in the stack pointer, the 6809 has two stack registers!), so I thought it might be fun to program a small game for the Vectrex.
The Vectrex was a commercial failure for Milton Bradley (of board game fame), only 29 games were officially released. But the Vectrex has a very active community today with more than a 100 new games or improved versions of old ones released since its discontinuity. Studios like Fury Unlimited or Binary Star Software keep developing and releasing games to this very day (there is even a magazine).
I plan to document the whole game development process here from the very first sketches and lines of code to the final cartridge. In this first post, I’ll describe the basic design and mechanics of the game.
The Game
Since this is my first Vectrex project I wanted to start with something simple. The Vectrex was marketed as the arcade experience brought to your home. So why not port an old arcade game to the Vectrex? Meet Sea Wolf by Midway:
Originally released in 1976 (although there were electro-mechanical predecessors) it was later ported to several Atari and Commodore home computers as Sea Wolf II with improved color graphics.
I think this game will translate very nicely on the Vectrex. The original too was restricted to a black and white screen (with a blue overlay for the water’s color). The control scheme is simple too, the vector graphics will add an extra layer of charm to the game I believe.
Let’s get started and see how to port this game to the Vectrex.
The Basic Process
The development will take the form of the following steps:
- Nail down the basic game design
- Write a simple demo to test the design
- Test the game to balance out all elements (points per ship sunk, reload time, etc.)
- Design a PCB for the cartridge
- Test on actual hardware
- More debugging
- ???
- Profit!
That’s the basic procedure I will follow. Not perfect, but for a first project hopefully adequate.
Basic Game Design
The rules for the game are quite simple:
- The player has a certain amount of time to sink as many ships as possible
- Four torpedoes can be shot in succession, then the player must wait shortly for the torpedo tubes to reload
- The player aims the torpedoes with the help of an on-screen cross-hair (of the periscope) controlled by the analog stick; torpedoes are fired with a simple press of a controller button
- There are three layers of lanes where ships can appear
- Different ship types give different amounts of points
- Hitting a mine will only destroy the torpedoes, but no points are awarded
- If the player gathers a certain amount of points within the time limit, they are rewarded with additional play time
These are the condensed game rules. Pretty straight forward.
Next, I need to settle for a name:
This was a simple process. I wrote down words I associate with submarines, naval warfare, and ships. Then I combine them to find a cool title. I settled for Sub Attack, it’s simple and in line with the general style the original Vectrex game names took.
Now, let’s do a weird screen mock-up sketch:
This shows all game elements. On top of the screen, there are three crucial pieces of information for the player: the time left, torpedoes left, and the current score. I also plan to add the score for the next time bonus below the current score.
Ships will move in three different layers/rows horizontally. The farther away they are, the more points they will awards. So will smaller ships that move faster.
This is my basic idea for the different ships and how much points they award:
This is obviously just a first idea. This will need testing to get the balance right. This is also closely tied to the question of how many ships should be on screen at any time. There might be some technical limitations set by the Vectrex. I will investigate this when I write the subroutines for this.
Next, sound design. The Vectrex has an awesome sound chip, the General Instrument AY-3-8910. Here is a first rough list of the sounds I will need for Sub Attack:
- A catchy theme for the start screen (think Das Boot or Hunt for Red October)
- Sound of a torpedo fired; pressurized air leaving the tube
- Sound of a running torpedo; fast screw turning in water
- Sound of a PT boat; whenever a PT boat enters the screen, this sound plays
- Explosion sound; torpedo hits a ship or mine
- Sonar ping sound
- Game Over sound; played when time runs out
This list is by no means exhaustive. The player can hear the PT boat racing across the screen. This is a hint to the player since the PT boat is the smallest enemy but also awards the most points. The sonar ping could be used to warn the player of the time limit. The closer the clock runs to zero, the more intense and frequent the sonar pings get.
For good measure, I even did a start screen mock-up:
Conclusion
That’s pretty much the whole basic design of the game. As I said, it’s a simple arcade game that I believe will translate well to the Vectrex. Next time I will start to design some of the enemies/ships assets and write simple routines to display them on the Vectrex. This will include some basic game logic first in pseudo code, and then in actual machine code.
For comments and questions please use the comment function below.