Bluish Coder

Programming Languages, Martials Arts and Computers. The Weblog of Chris Double.


2007-02-04

Lunar Rescue Emulator

The Space Invaders emulator I wrote is actually a generic 8080 emulator. Quite a few arcade games used similar hardware to the old Space Invaders machines.

One of those is Lunar Rescue. I added a Lunar Rescue emulator by using the Space Invaders routines but with the Lunar Rescue ROM code loaded. This works fine. The sounds are probably slightly different and the colours are not right but the game plays fine. I'll work on these issues to get it as correct as possible.

To implement the Lunar Rescue game I create a TUPLE specific for the game and delegated all functionality to the Space Invaders TUPLE. To implement the correct colours and sounds I'll add methods specific to the Lunar Rescue TUPLE. Factor does OO easily.

I did some refactoring of Space Invaders and now running the 'apps/space-invaders' module brings up a window with buttons for the supported games. Clicking a button runs Space Invaders or Lunar Rescue.

The ROM files have moved too. They now live in subdirectories off 'apps/space-invaders/resources'. You'll need to create 'invaders' and 'lrescue' subdirectories, each containing the require ROM files. These are specifically:

  • invaders/invaders.e
  • invaders/invaders.f
  • invaders/invaders.g
  • invaders/invaders.h
  • lrescue/lrescue.1
  • lrescue/lrescue.2
  • lrescue/lrescue.3
  • lrescue/lrescue.4
  • lrescue/lrescue.5
  • lrescue/lrescue.6

You'll notice I've gone towards using the separate ROM files for Space Invaders rather than the complete 'invaders.rom'. This is to make it easier so you don't have to manually concatenate the files.

Tags


This site is accessable over tor as hidden service 6vp5u25g4izec5c37wv52skvecikld6kysvsivnl6sdg6q7wy25lixad.onion, or Freenet using key:
USK@1ORdIvjL2H1bZblJcP8hu2LjjKtVB-rVzp8mLty~5N4,8hL85otZBbq0geDsSKkBK4sKESL2SrNVecFZz9NxGVQ,AQACAAE/bluishcoder/-61/


Tags

Archives
Links