# Early mainframe games

Mainframe computers are computers used primarily by businesses and academic institutions for large-scale processes. Before personal computers, first termed microcomputers, became widely available to the general public in the 1970s, the computing industry was composed of mainframe computers and the relatively smaller and cheaper minicomputer variant. During the mid to late 1960s, many early video games were programmed on these computers. Developed prior to the rise of the commercial video game industry in the early 1970s, these early mainframe games were generally written by students or employees at large corporations in a machine or assembly language that could only be understood by the specific machine or computer type they were developed on. While many of these games were lost as older computers were discontinued, some of them were ported to high-level computer languages like BASIC, had expanded versions later released for personal computers, or were recreated for bulletin board systems years later, thus influencing future games and developers.
Early computer games began to be created in the 1950s, and the steady increase in the number and abilities of computers over time led to the gradual loosening of restrictions on access to mainframe computers at academic and corporate institutions beginning in the 1960s. This in turn led to a modest proliferation of generally small, text-based games on mainframe computers, with increasing complexity towards the end of the decade. While games continued to be developed on mainframes and minicomputers through the 1970s, the rise of personal computers and the spread of high-level programming languages meant that later games were generally intended to or were capable of being run on personal computers, even when developed on a mainframe. These early games include Hamurabi, an antecedent of the strategy and city-building genres; Lunar Lander, which inspired numerous recreations in the 1970s and 1980s; Civil War, an early war simulation game; Star Trek, which was widely ported, expanded, and spread for decades after; Space Travel, which played a role in the creation of the Unix operating system; and Baseball, an early sports game and the first baseball game to allow player control during a game.

## Background

Mainframe computers are powerful computers used primarily by large organizations for computational work, especially large-scale, multi-user processes. The term originally referred to the large cabinets called "main frames" that housed the central processing unit and main memory of early computers. Prior to the rise of personal computers, first termed microcomputers, in the 1970s, they were the primary type of computer in use, and at the beginning of the 1960s they were the only type of computer available for public purchase. Minicomputers were relatively smaller and cheaper mainframe computers prevalent in the 1960s and 1970s, though they were still not intended for personal use. One definition from 1970 required a minicomputer to cost less than US$25,000. In contrast, regular mainframes could cost more than US$1,000,000.
By the end of the 1960s, mainframe computers and minicomputers were present in many academic research institutions and large companies such as Bell Labs. While the commercial video game industry did not yet exist at that point in the early history of video games and would not until the early 1970s, programmers at these companies created several small games to be played on their mainframe computers. Most of these spread only to other users of the same type of computer and therefore did not persist as older computer models were discontinued; several, however, inspired future games, or were later released in modified versions on more modern systems or languages. These early mainframe games were largely created between 1968 and 1971; while earlier games were created they were limited to small, academic audiences. Mainframe games also continued to be developed through the 1970s, but the rise of the commercial video game industry, focused on arcade video games and home video game consoles, followed by the rise of personal computers later in the decade, meant that beginning in the 1970s the audience and developers of video games began to shift away from mainframe computers or minicomputers, and the spread of general-purpose programming languages such as the BASIC programming language meant that later mainframe games could generally be run on personal computers with minimal changes, even if initially developed on a mainframe.

## Early games

The very first computer games began to appear in the 1950s, starting with Bertie the Brain, a computer-based game of tic-tac-toe built by Dr. Josef Kates for the 1950 Canadian National Exhibition. While the status of these games as video games depends on the definition used, the games developed during this time period ran on the large antecedents of mainframe computers and were primarily developed for the purposes of academic research or to showcase the technological development of the computers on which they ran. Access to these computers, located almost exclusively in universities and research institutions, was restricted to academics and researchers, preventing any development of entertainment programs. Over the course of the decade, computer technology improved to include smaller, transistor-based computers on which programs could be created and run in real time, rather than operations run in batches, and computers themselves spread to more locations.
By the 1960s, improvements in computing technology and the early development of relatively cheaper mainframe computers, which would later be termed minicomputers, led to the loosening of restrictions regarding programming access to the computers. At the Massachusetts Institute of Technology (MIT), access to the TX-0 experimental computer was opened to students and employees of the university. This in turn led to the development of programs that in addition to highlighting the power of the computer also contained an entertainment aspect. The games created for the TX-0 by the small programming community at MIT included Tic-Tac-Toe, which used a light pen to play a simple game of noughts and crosses against the computer, and Mouse in the Maze, which let players set up a maze for a mouse to run through. When the Digital Equipment Corporation (DEC) PDP-1 computer was installed at MIT in 1961, the community built a video game to showcase its abilities, Spacewar!, which then became the first known video game to spread beyond a single computer installation as it was copied and recreated on other PDP-1 systems and later on other mainframe computers.
Over the course of the decade, computers spread to more and more companies and institutions, even as they became more powerful—by 1971, it is estimated that there were over 1000 computers with monitors, rather than the few dozen at the beginning of the 1960s. While different computers could generally not run the same programs without significant changes to the programs' code, due to differences in the physical hardware or machine languages, the expansion of the computing industry led to the creation of catalogs and user groups to share programs between different installations of the same series of computers, such as DEC's PDP line. These catalogs and groups, such as the IBM program catalog and the Digital Equipment Computer Users' Society (DECUS), shared small games as well as programs, including, for example, "BBC Vik The Baseball Demonstrator" and "Three Dimensional Tic-Tack-Toe" in the April 1962 IBM catalog, and dice games and question and answer games in the DECUS newsletter. The Sumerian Game (1964) for the IBM 7090, a strategy video game of land and resource management, was the first educational game for children. Mainframe games were developed outside of the IBM and DEC communities as well, such as the 1962 Polish Marienbad for the Odra 1003, and blackjack, hangman, and tic-tac-toe on the United States Air Force and RAND's JOSS.
By the latter half of the 1960s, higher-level programming languages such as BASIC which were able to be run on multiple types of computers further increased the reach of games developed at any given location. While most games were limited to text-based designs, rather than visual graphics like Spacewar, these games became more complicated as they reached more players, such as baseball and basketball simulation games. The November 1969 DECUS catalog listed 37 games and demos including Spacewar and The Sumer Game, compared to 58 scientific and engineering applications, the most common intended purpose of a minicomputer. Access to the computers themselves was also extended to more people by systems such as the Dartmouth Time-Sharing System (DTSS), which connected several thousand users through many remote terminals to a central mainframe computer. By the 1967–68 school year the DTSS library of 500 programs for the system included, John G. Kemeny and Thomas E. Kurtz wrote, "many games". Over a quarter of the system's usage was for casual or entertainment purposes, which Kemeny and Kurtz welcomed as helping users to become familiar with and not fear the computer. They noted that "we have lost many a distinguished visitor for several hours while he quarterbacked the Dartmouth football team in a highly realistic simulated game". By 1972 the football simulation had become a multiplayer video game, supporting head-to-head play.
Mainframe games were also played and watched by people outside of college campuses. In 1968, Cornell University School of Hotel Administration funded the development of two business games: Cornell Hotel Administration Simulation Exercise (CHASE) and Cornell Restaurant Administration Simulation Exercise (CRASE). The former was a backronym, having been developed by Prof. Robert Chase and his students. Notably the restaurant game featured competitive play, with teams of players managing competing restaurants. The games were made playable for attendees at national conventions of the American Hotel & Motel Association and the Club Managers Association of America in 1969. On Christmas Eve, 1970, the BBC television program Tomorrow's World broadcast a mainframe computer racing game played between TV presenter Raymond Baxter and British two-time Formula One world champion Graham Hill on their Christmas special. The game was written by IBM-employee, Ray Bradshaw, using CALL/360 and required two data center operators to input the instructions. "The race was run to show that computers could be fun."

## 101 BASIC Computer Games

In 1971, DEC employee David H. Ahl converted two games, Hamurabi and Lunar Lander, from the FOCAL language to BASIC, partially as a demonstration of the language on the DEC PDP-8 minicomputer. Their popularity led him to start printing BASIC games in the DEC newsletter he edited, both ones he wrote and reader submissions. In 1973, he published 101 BASIC Computer Games, containing descriptions and the source code for video games written in BASIC. The games included were written by both Ahl and others, and included both games original to the language and ported from other languages such as FOCAL. Many of these ports were originally mainframe computer games. 101 BASIC Computer Games was a best seller with more than 10,000 copies sold, more sales than computers in existence at the time. Its second edition in 1978, BASIC Computer Games, was the first million-selling computer book. As such, the BASIC ports of mainframe computer games included in the book were often more long-lived than their original versions or other mainframe computer games.
Hamurabi in particular is mostly known for its appearance in Ahl's book. After hearing of The Sumerian Game, Doug Dyment at DEC created his own The Sumer Game for fellow employee Richard Merrill's newly invented FOCAL programming language. The game consists of ten rounds wherein the player, as the ancient Babylonian king Hammurabi, manages how much of their grain to spend on crops for the next round, feeding their people, and purchasing additional land, while dealing with random variations in crop yields and plagues. Multiple versions of the game were created for the FOCAL and FOCAL-69 languages, but an expanded, uncredited version of the game was included in 101 BASIC Computer Games as Hamurabi, and later versions of the game, even in FOCAL, referenced the new title over the old. Hamurabi influenced many later strategy and simulation games and is an antecedent to the city-building genre.
The other game Ahl originally ported to BASIC, Lunar Lander, appeared in the book in three different forms. The original version of the game was called Lunar, and was originally written in FOCAL for the PDP-8 by Jim Storer while a high school student in the fall of 1969. A different version called Rocket was written in BASIC by Eric Peters at DEC, and a third version, LEM, was written by William Labaree II in BASIC. Ahl converted Jim Storer's FOCAL version to BASIC, changed some of the text, and published it in his newsletter. A year or so later, all three BASIC versions of the game appeared in 101 BASIC Computer Games, under the names ROCKET (Storer version), ROCKT1 (Peters version), and ROCKT2 (Labaree version). All three text-based games required the player to control a rocket attempting to land on the Moon by entering instructions to the rocket in response to the textual summary of its current position and heading relative to the ground. Ahl and Steve North converted all three versions to Microsoft BASIC, changed the collective name to Lunar Lander, and published them in Creative Computing magazine in 1976; that name was used in the 1978 edition of BASIC Computer Games.
Another game from the book is Civil War, a text-based computer game that puts the player against the computer in a simulation of the American Civil War. Civil War originated on multi-user mainframe computers in 1968, and simulates fourteen major battles of the conflict, with the human player as the South and the computer as the North. The player can control four direct variables which interact to determine a battle's outcome: how much of their money to spend on food, salaries, and ammunition, and which of four offensive or four defensive strategies to use. The side with the fewest casualties wins a battle, and if the player wins eight or more battles they win the game. Ahl credited the game in 101 BASIC Computer Games to L. Cram, L. Goodie, and D. Hibbard, students at Lexington High School, and to G. Paul and R. Hess of "TIES" for converting the game into a two-player game. Civil War was later one of a number of text-based games available on early 1980s pay-to-play systems.
Possibly the most popular of the mainframe games that appeared in Ahl's book was Star Trek. The game is a text-based computer game that puts the player in command of the Starship Enterprise on a mission to hunt down and destroy an invading fleet of Klingon warships. Unlike the other text-based games, however, it did not use written responses to player input, but instead had character-based graphics, with different characters used as graphical symbols to represent objects. It was initially developed by Mike Mayfield in 1971 on an SDS Sigma 7 mainframe. The game was also unlike many of the other mainframe games in the book in that it was originally written in BASIC; by the time the book was published, it had been widely copied among minicomputer and mainframe systems and modified into several versions. It was one of these, renamed by Ahl as Space War, that appeared in 101 BASIC Computer Games. The 1978 version of the book contained a Microsoft BASIC port of Super Star Trek, an expanded version of the game first written in 1974, and this version was ported to numerous personal computer systems of the era; Ahl stated in the book that it was difficult to find a computer installation that did not contain a version of Star Trek. Multiple updated versions in a wide variety of languages have been made since. By 1980, Star Trek was described by The Dragon magazine as "one of the most popular (if not the most popular) computer games around", with "literally scores of different versions of this game floating around".

## Other games

Some mainframe games that did not appear in 101 BASIC Computer Games have still had a lasting impact. One such game was Space Travel, developed by Ken Thompson in 1969, which simulates travel in the Solar System. The player flies their ship around a two-dimensional scale model of the solar system with no objectives other than to attempt to land on various planets and moons. The player can move and turn the ship, and adjust the overall speed by adjusting the scale of the simulation. The ship is affected by the single strongest gravitational pull of the astronomical bodies. The game was developed at Bell Labs, and was ported during 1969 from the Multics operating system to the GECOS operating system on the GE 635 computer, and then to the PDP-7 minicomputer. While porting the game to the PDP-7, Thompson developed ideas for his own operating system, which later formed the core of the Unix operating system. Space Travel never spread beyond Bell Labs or had an effect on future games, leaving its primary legacy as part of the original push for the development of Unix.
Another influential early mainframe game was Baseball, a sports game that was created on a PDP-10 minicomputer at Pomona College in 1971 by English major Don Daglow. Baseball was the first baseball video game that allowed players to manage the game as it unfolded, rather than just picking players at the beginning of a game. The program is documented at the National Baseball Hall of Fame and Museum in Cooperstown, New York. Baseball was continually updated through 1974, and distributed to other PDP-10 installations. The text-based game had each player control the pitcher or the batter; they would enter their intention to, for example, pitch to or walk the batter, or switch hitters. The batting player could direct on-base players to steal, and the batter to hit. The results of the play would be printed out onto paper as a verbose description, like a radio description of the game. Daglow went on to develop more sophisticated baseball games in 1983 with Intellivision World Series Baseball, and 1987 with Earl Weaver Baseball, as well as numerous other games.