In the fall of 1961, a PDP-1 was installed in the "kludge room"
May 2, 2014 6:41 AM   Subscribe

Spacewar! was perhaps the first true video game. Now, thanks to the Internet Archive, you can play it in your browser.
posted by Chrysostom (14 comments total) 19 users marked this as a favorite
 
A strange game. The only winning move is to play it and beat the other player.
posted by FAMOUS MONSTER at 6:52 AM on May 2, 2014 [5 favorites]


I just got a little spiny thing at the bottom and the splash screen. Man, the first video games were boring.
posted by cjorgensen at 7:11 AM on May 2, 2014


not working for me. follow the directions and bubkis
posted by leotrotsky at 7:13 AM on May 2, 2014


That does not work for me. This, however, does.
posted by designbot at 7:21 AM on May 2, 2014 [3 favorites]


A great history piece "The origin of Spacewar" was published by the old-school Creative Computing, which now of course is a piece of tech history itself.
posted by Doktor Zed at 7:37 AM on May 2, 2014


Here's another browser version of Spacewar. Lacks the blinkenlights, but then again it loads faster. What's really cool to me is both are running the actual original code; pure emulation, not a port or rewrite. (Fun fact; one of the guys who worked on this version is Vadim Gerasimov, who also was one of the folks who created the original Tetris.)
posted by Nelson at 7:46 AM on May 2, 2014 [1 favorite]


What no 3D, Surround Sound, Multi-player and social Gaming Integration? Bah!
posted by homodigitalis at 8:21 AM on May 2, 2014


Heh - I used to play this on my brother's Vectrex. The acceleration was much stronger and the game was more fun, but it's still nice to be reminded.
posted by YAMWAK at 8:53 AM on May 2, 2014


The now defunct GAMBIT Game Lab did an Arduino reimplementation of Spacewar! for the game's 50th anniversary.
Along the way, they made some interesting posts about reverse engineering the game.

digital archaeology
Think in bits. Spacewar! is written very close to the machine. The programmers have used a frightening array of bitwise manipulation tricks that you don't often see in modern programming. They rotate bits in memory using bit-shifting so that they can store two short numbers in space normally used for one long number. They shift number representations around so that they're in the left or right side of a memory address depending on where a particular instruction call requires that it needs to be, which crops up quite frequently with the display instruction "dpy". They use clever number representations, such as 2's complement, to do fancy arithmetic tricks. They use MACRO to repeatedly double numbers in the preprocessing stage so that they get bit-shifted to the location in memory that they want before execution. They add together the bit codes of instructions to create combined instructions. These tricks are very rarely commented and working out exactly what this "clever" code is doing and why often requires a lot of poking around and reverse engineering.
the star field
When we first started looking at the source code for Spacewar! we were struck by a strange section of code at the end, which was solely made up of repeated instructions along the lines of the code in the image on the right. A little bit of reflection and some background reading lead us to discover that this code was setting up a table of all the coordinates of the stars displayed in Spacewar!'s background. The code for doing this is a program in itself called Expensive Planetarium, written by Peter Samson, which displays a faithful recreation of the night sky as visible from MIT and was originally independent of Spacewar, but was later integrated into it.
and the vector graphics:
With this discovery we had enough information to try reconstructing the outlines of the ships from the encodings by hand. Anxiously, we started sketching the outline of the first ship and were disappointed mid way through to find that it seemed like it mostly just a straight line and that there weren't enough instructions to possibly encode the whole outline of a ship. After reflecting for a moment though, we realized it makes sense that the needle ship would be mostly straight, so that was actually not a problem, but the final realization that made everything fit together was that only half of each ship's outline was being encoded; the programmers must have reflected them to draw the other halves.
and a final post on implementation.

the peculiar spacewar!
posted by zamboni at 8:57 AM on May 2, 2014 [6 favorites]


There's no "Give us 5 stars at Google Play to unlock ship controls" button? Man, old games are weird.
posted by Pyrogenesis at 9:37 AM on May 2, 2014 [2 favorites]


I remember playing several hours of this against a friend on his Amiga in the early 90s. It may have even been using a PDP emulator.

There was an option to make your shots susceptible to gravity (giving them mass?), and my favorite tactic was to fire towards the star so it would slingshot my barrage towards the enemy ship at great speed.
posted by ceribus peribus at 12:19 PM on May 2, 2014


From such humble beginnings eventually arose the Zoq-Fot-Pik.
And a whole bunch of other stuff. But I like the Zoq-Fot-Pik the most.

posted by m@f at 1:30 PM on May 2, 2014 [1 favorite]


Brings back memories. The original interface was toggle switches on the front panel of the CPU - one of you worked switches 0-3, the other 14-17. The version I used had some enhancements - hyperspace, which appears to be missing from the one based on the 1961 source code; and conservation of angular momentum, with the turning controls simulating thrusters (ie the longer you held the switch down, the faster your rotation, and to stop rotating you had to apply counter-thrust).

But what' I really miss is the scintillation of the starfield on the vector display - I don't know if this was intentional, or an artifact of the display speed (it had no display memory and a low-persistence phosphor), but the effect was quite remarkable, especially when you were used to interacting with computers on an asr-33.
posted by mr vino at 2:27 PM on May 2, 2014 [3 favorites]


I've played this at the Computer History Museum on an actual PDP-1 and talked to the person who coded it.
posted by caphector at 3:40 PM on May 2, 2014 [3 favorites]


« Older Work the Line   |   Your crush mileage may vary. Newer »


This thread has been archived and is closed to new comments