The Zapper was the light gun sold with the Nintendo Entertainment System, and for millions of players it meant Duck Hunt: shoot the duck, and if you miss, the dog laughs at you. What surprises programmers is how little the gun knows. It cannot tell where it is pointing. It reports a single bit, light or no light, and the game works out what you hit by flashing the targets white one at a time and watching for the moment the gun sees one.
Fast facts
- Manufacturer: Nintendo.
- Released: Famicom light gun, Japan, February 1984; Zapper, US, October 1985.
- Connection: an NES controller port, usually port 2 (the Famicom version plugs into the expansion port).
- Output: two bits: light sensed (bit 3) and trigger (bit 4).
- Launch games (US): Duck Hunt, Hogan’s Alley and Wild Gunman, all October 1985.
- Colour: grey at first; later orange.
- Needs: a CRT television.
From toy guns to the NES
Nintendo was making light guns a decade before the Famicom. In the early 1970s Gunpei Yokoi and Masayuki Uemura, who had come from Sharp, found that a small solar cell could act as a light sensor. Their Beam Gun toys fired a “thin beam of light” at targets carrying such a cell, which could release a spring or make a plastic bottle burst apart. According to David Sheff, more than a million sold.
The Famicom reversed the arrangement. Its light gun, sold in Japan from February 1984 and shaped like a revolver, carried the sensor, and the television became the target. When Nintendo of America prepared the machine for the United States, it redesigned the gun as a futuristic pistol: in Sheff’s words, “The Zapper gun might have belonged to Luke Skywalker.” Together with the robot R.O.B., it was the NES’s headline accessory, and both came in the Deluxe Set, which a November 1986 American mail-order advert listed at $149. The Zapper alone was $24.
In Britain, Nintendo’s 1987 launch advert promised that “the astonishing light sensitive Zapper Gun lets you shoot moving targets with pinpoint accuracy from up to 16 feet!”
How it works
The Zapper does not report where it is pointing. It reports whether it can see light at this instant, and whether the trigger is being pulled. Everything else is the game’s work. The usual method, described by the NESdev community from the games themselves, goes like this:
- Wait for the trigger.
- During the vertical blank, while the screen is dark, check that the gun is not seeing light. If it is, the player is aiming at a lamp or a window. If the light bit reads as “seen” even then, a standard controller is probably plugged in instead of a Zapper. Do this late in the blank, so that light from the bottom of the previous picture has time to die away in the sensor.
- For each target, draw a black screen with a single white box where that target is, and watch the light bit for the whole frame.
- If the gun sees light, that target was hit. If not, try the next target. If none lights it up, the shot missed.
- Put the normal picture back.
Each flash lasts a single frame. A game can speed this up by first turning the whole screen white and timing how far down the picture the beam gets before the gun sees it. That gives the height the gun is aimed at and rules out targets that could not match. Not every game bothers to check at all: in Wild Gunman’s one-outlaw Game A, all that matters is when you pull the trigger.
Why it needs a CRT
A CRT draws the picture as a moving spot of light, one line at a time, about 15,700 lines a second. The Zapper’s photodiode has a filter tuned to roughly that frequency. It picks up the quick flash as the spot passes, and ignores steady light from lamps and windows. Aimed at a white area, it stays triggered for about 26 scanlines as the signal fades.
Most modern flat screens fail on both counts. An LCD shows each frame as a steady image, so the filter treats it much like room light and throws most of the signal away. And modern televisions delay the picture while they process it, but Zapper games expect the flash to reach the gun on the frame they drew it. Clone guns with weaker filters, together with patched games that allow for the delay, can get some Zapper games working on a modern set.
The trigger has three states
The trigger is not a simple switch. The official Zapper returns 0 with the trigger at rest, 1 while it is halfway in, and 0 again once it is “pulled all the way to where it goes clunk”. A 10 µF capacitor in the gun, against a 10 kΩ pull-up resistor in the console, means it takes about 100 ms to read as released again after a half-pull. Most games fire when the bit changes from 1 to 0, which is why cheaper clone guns with a plain switch still work.
Games
- Duck Hunt (US, 1985): “You’ve only got three shots to bag this duck,” the British advert said, “and if you miss, even your dog laughs at you.”
- Hogan’s Alley (US, 1985): a shooting range in which, as the British advert put it, you “shoot the gangsters”.
- Wild Gunman (US, 1985): quick-draw duels against outlaws.
- Gumshoe (US, 1986).
- Barker Bill’s Trick Shooting (1990): four shooting-gallery games, including balloons and flying saucers.
- Mechanized Attack and Operation Wolf: military shooters that could be played with the Zapper or a controller.
Grey and orange
The first American Zappers were grey. Later ones were orange. Asked about the two colours in 2003, the classic-gaming fanzine Digital Press explained that realistic toy guns had been “mistaken for real guns with disastrous results”, and that “the Zapper and other game and toy guns were remade in bright colors to help distinguish them from the real deal”. Modern accounts date the orange Zapper to 1989, after a 1988 US law required toy guns to look different from real ones.
Other versions
The Famicom’s light gun sends the same two signals, but plugs into the Famicom’s expansion port. The Zapper built for Nintendo’s Vs. System arcade machines is not compatible: it speaks the standard controller’s serial protocol, and its light bit is inverted.
Sources
- David Sheff, Game Over (1993; GamePress edition, 1999): chapter “In Heaven’s Hands” (Yokoi, Uemura and the Beam Gun) and chapter “Enter the Dragon” (the Zapper in the Advanced Video System and its redesign).
- Digital Press, May/June 1993, p. 5: release dates of the first NES games, including the light gun games.
- Ahoy! issue 35, November 1986: mail-order prices for the Zapper and the Deluxe Set.
- CRASH issue 41, June 1987: Nintendo UK launch advertisement (the Zapper’s range, Duck Hunt and Hogan’s Alley); the same advertisement ran in issue 44, September 1987.
- Nintendo Power issue 14, July 1990 (Mechanized Attack, Zapper or controller) and issue 16, September 1990 (Barker Bill’s Trick Shooting; Operation Wolf with a Zapper option).
- Digital Press issue 52, May/June 2003, letters: why the Zapper changed colour.
- NESdev Wiki, “Zapper”: the output bits, the target-flashing method, the vertical-blank check, sensor timing and the CRT filter, display lag, the trigger, and the Famicom and Vs. System versions (web, secondary). https://www.nesdev.org/wiki/Zapper
- Wikipedia, “NES Zapper”: the Famicom light gun’s release date and revolver styling, the US release date, and the date of the orange version (web, secondary).
See also
- Duck Hunt
- R.O.B.: the other Deluxe Set peripheral, which uses the same kind of light sensor.
- Light gun: light guns on other machines.
- Nintendo Entertainment System
- Gunpei Yokoi and Masayuki Uemura