Spotlight › 1942

1942, an air-combat game for the 8088

You fly a fighter up a scrolling sea of islands while enemy planes come at you in formations. This is a new game in 8086 assembly after the 1942 arcade game, and it scrolls with the graphics card's own hardware so that a 4.77 MHz IBM PC keeps up.

stages
32
graphics cards
VGA, CGA
crowded sky, 4.77 MHz
6.7 frames/s

1942 has a disk of its own in the release, and is on the everything set, the live USB image and CD, and The Wire.

Full screen, VGA
1942 full screen: a strip of dark blue sea between green islands with sandy beaches and reefs. A grey twin-boom fighter at the bottom fires pairs of shots upward toward three dark green enemy planes, one of them bursting. The top line reads 000100, L3 R3, Stage 32.
Stage 32, full screen on VGA. The top line is the score, the lives (L) and the rolls (R). Stages count down from 32, as they do in the arcade game.

What it is

A shooting game from 1984, rebuilt for a machine from 1981.

1942 was an arcade game Capcom released in 1984, and later on home consoles. You fly a fighter plane over the Pacific. The screen scrolls slowly upward, as if you were flying forward over the sea, and enemy fighters and bombers fly in from the top and the sides, in ones and in formations. You shoot them down, avoid their bullets, and keep going until the stage ends.

This 1942 is a new program for the 8086. Nothing is emulated. It plays by the same idea, with its own aircraft movement, timing and artwork made for this game. It is an adaptation, not a Capcom product, and is not made or endorsed by Capcom.

There are 32 stages. A mission begins with a takeoff from a carrier and ends with a landing and a results screen, which gives bonuses for your hit rate and for rolls you did not use. Shoot down a whole orange formation and it leaves a power-up behind: stronger guns, two wingmen who fly and fire beside you, a blast that clears the screen, an extra roll or an extra life. Two players can take turns, each with their own score, lives and stage.

The title screen opens in a window. Enter takes off full screen, and Esc goes back to the desktop with the game kept where you left it. Arrows move, Space or Z fires, X rolls (three rolls a stage, each a moment where nothing can hit you), P pauses and M turns the sound off.

See it running

In a window on the desktop, and full screen on VGA.

Title screen
The 1942 window on the os8088 desktop: 1942 in large green outlined digits on black, then 1 Player with a small plane beside it, 2 Players, and the line 1/2 Select, Enter Start, H Controls.
The title screen, in a window. It is uncovered a few rows at a time so the desktop stays responsive on a 4.77 MHz machine. 1 or 2 chooses the players, and Enter takes off.
The controls
The 1942 window showing the controls under the logo: Arrows Move, Space / Z Fire, X Roll, P Pause, M Sound, C CGA Palette, Escape / F Returns to Desktop, H / Esc Close Help, Enter Take Off.
The controls. H shows them, and H or Esc closes them. C changes the colours on CGA.
A formation
1942 full screen a few seconds later: several dark green enemy planes spread across the sea between the islands, flying down toward the grey fighter at the bottom. The score reads 000150.
A formation coming in. Enemy planes fly their own paths down the screen while the sea scrolls under them.

How it works

What lets a 4.77 MHz processor scroll a whole screen.

Scrolling

The card moves the picture

Redrawing a whole screen of scenery every frame is far more than an 8088 can do. Instead the game tells the graphics card to start showing the picture from a different place in its memory, which moves everything on screen at once for the cost of a few instructions. Only the new rows of scenery at the top are drawn each frame, along with the planes and bullets that moved.

On VGA the game uses a 320 by 240 mode with room for two screens in the card's memory: it draws into the hidden one and then shows it. On CGA, the colour card IBM sold with the first PC, it uses the four-colour 320 by 200 mode.

Speed

Measured with the sky full

The test fills the sky beyond what the game ever sends at once: 12 aircraft, 16 of your shots, 16 enemy bullets and four explosions. On an emulated IBM PC with an 8088 at 4.77 MHz, counting the processor's own cycles:

1942's frame rate in a crowded sky on a 4.77 MHz IBM PC
cardaverageslowest frame
VGA6.73 frames/s5.97 frames/s
CGA5.56 frames/s5.16 frames/s

On a faster PC the game does not run faster than intended: it moves at most 18.2 times a second, the rate of the PC's system clock.

The pictures

Prepared once, on the computer that builds it

The planes, the bullets and the three kinds of scenery -- open sea, reefs and a harbour -- are converted when the game is built into the exact layout each graphics card wants, and stored in files beside the program. On CGA each plane is turned into a short piece of machine code that writes its own pixels, which is faster than copying it a byte at a time. The game holds them in three blocks of 64KB, and it is made for a 640KB machine.

The sound

FM music, and real gunfire on a Sound Blaster

On an AdLib or Sound Blaster the music and effects play on the card's FM synthesiser, a chip that makes several voices at once. A Sound Blaster also plays recorded gunfire and explosions, which the card fetches by itself while the game carries on drawing. The recordings are freely licensed sounds from OpenGameArt.org. With no card, the PC speaker plays the tones.

What it does not do

Where it differs from the arcade game.

  • It is not the arcade game's program or artwork. The aircraft, the scenery and the enemy patterns are this game's own.
  • The game itself needs VGA or CGA. On Hercules, the black and white graphics card from 1982, you can see the title and the controls, but not play.
  • On a 4.77 MHz PC the game slows down when the sky is crowded. A late frame is not made up for later, so play slows rather than jumps.
  • High scores last until you close the game.
  • The 360KB disk leaves out the recorded gunfire and explosions for room, so a Sound Blaster plays the FM effects instead.

Run it

From its own disk, the everything set, or The Wire.

  1. Boot os8088 from the system disk, and put 1942's disk in drive B: 1942.img at 1.44MB, or 1942-360.img for a 360KB XT. Both are in the release zip.

  2. Double-click Disk B, then 1942.O88.

  3. Press Enter to take off.

It is also in a 1942 folder on the everything set and on the live USB image and CD. With a network card you can fetch it from The Wire instead: pick 1942 and press Add to Disk. It writes thirteen files, 226KB in all, into the folder you choose, so a 360KB floppy has room, and that includes the recorded sounds the 360KB disk leaves out.

Keep 1942.O88 and its .GFX, .V42 and .C42 files together in one folder when you copy it. They hold the pictures.