Colossal Cave Adventure

Colossal Cave Adventure (also known as ADVENT, Colossal Cave, or Adventure) is a text adventure game, developed between 1975 and 1977 by Will Crowther for the PDP-10 mainframe. The game was expanded upon in 1977 with help from Don Woods, and other programmers created variations on the game and ports to other systems in the following years.
In the game, the player controls a character through simple text commands to explore a cave rumored to be filled with wealth. Players earn predetermined points for acquiring treasure and escaping the cave alive, with the goal to earn the maximum number of points offered. The concept bore out from Crowther's background as a caving enthusiast, with the game's cave structured loosely around the Mammoth Cave system in Kentucky.
"Colossal Cave Adventure" is the first known work of interactive fiction and, as the first text adventure game, is considered the precursor for the adventure game genre. "Colossal Cave Adventure" also contributed towards the role-playing and roguelike genres.
Gameplay.
"Adventure" has the player's character explore a mysterious cave that is rumored to be filled with treasure and gold. To explore the cave, the player types in one- or two-word commands to move their character through the cave, interact with objects in the cave, pick up items to put into their inventory, and other actions. The program acts as a narrator, describing to the player what each location in the cave has and the results of certain actions, or if it did not understand the player's commands, asking for the player to retype their actions. (The player's commands are shown here in lower case, and the program's replies are in all-capitals.)
The program's replies are typically in a humorous, conversational tone, much as a dungeon master would use in leading players in a tabletop role-playing game. A notable example is when the player dies after falling into a pit.
Certain actions may cause the death of the character (the player has three lives), requiring the player to start again. The game has a point system, whereby completing certain goals earns a number of predetermined points. The ultimate goal is to earn the maximum number of points (350 points), which partially correlates to finding all the treasures in the game and safely leaving the cave.
Development.
Will Crowther was a programmer at Bolt, Beranek & Newman (BBN), and helped to develop the ARPANET (a forerunner of the Internet). Crowther and his wife Patricia were experienced cavers, having previously helped to create vector map surveys of the Mammoth Cave in Kentucky in the early 1970s for the Cave Research Foundation. In addition, Crowther enjoyed playing the tabletop role-playing game "Dungeons & Dragons" with a regular group which included Eric S. Roberts and Dave Lebling, one of the future founders of Infocom. Following his divorce from Pat in 1975, Crowther wanted to connect better with his daughters and decided a computerized simulation of his cave explorations with elements of his role-playing games would help. He created a means by which the game could be controlled through natural language input so that it would be "a thing that gave you the illusion anyway that you'd typed in English commands and it did what you said". Crowther later commented that this approach allowed the game to appeal to both non-programmers and programmers alike, as in the latter case, it gave programmers a challenge of how to make "an obstinate system" perform in a manner they wanted it to.
Developed over 1975 and 1976, Crowther's original game consisted of about 700 lines of FORTRAN code, with about another 700 lines of data, written for BBN's PDP-10 timesharing computer. The data included text for 78 map locations (66 actual rooms and 12 navigation messages) as well as 193 vocabulary words, travel tables, and miscellaneous messages. On the PDP-10, the program loads and executes with all its game data in memory. It required about 60k words (nearly 300kB) of core memory, which was a significant amount for PDP-10/KA systems running with only 128k words. Crowther's original version did not include any scorekeeping. Once the game was complete, Crowther showed it off to his co-workers at BBN for feedback, and then considered his work on the game complete, leaving the compiled game in a directory before taking a month off for vacation. During that time, others had found the game and it was distributed widely across the network, which had surprised Crowther on his return. Though titled in-game as "Colossal Cave Adventure", its executable file was simply named ADVENT, which led to this becoming an alternate name for the game.
One of those who had discovered the game was Don Woods, a graduate student at Stanford University in 1976. Woods wanted to expand upon the game and contacted Crowther to gain access to the source code. Woods built upon Crowther's code in FORTRAN, including more high fantasy-related elements based on his love of the writings of J.R.R. Tolkien. He also introduced a scoring system within the game and added ten more treasures to collect in addition to the five in Crowther's original version. His work expanded Crowther's game to approximately 3000 lines of code and 1800 lines of data. The data consisted of 140 map locations, 293 vocabulary words, 53 objects (15 treasure objects), travel tables, and miscellaneous messages. Like Crowther's original game, Woods' game also executed with all its data in memory but required somewhat less core memory (42k words) than Crowther's game. Don Woods continued releasing updated editions through to at least the mid-1990s.
Crowther did not distribute the source code to his version, while Woods, once finished with his improvements, widely distributed the code alongside the compiled executable. Woods' 1977 version became the more recognizable and "canon" version of "Colossal Cave Adventure" in part due to wider code availability, on which nearly all revisions described in the following section were based. Crowther's original code was thought to have been lost until 2007 when an unmodified version of it was found on Woods' student account archive.
Later versions.
Both Crowther's and Woods' version were designed to run on the PDP-10, enabling certain features unique to the platform. The PDP-10 architecture was 36-bit, with each word able to store five 7-bit ASCII characters.
The game's FORTRAN code compared player's commands with its vocabulary but using only the first five letters of each English word.
Unfortunately, this limitation was silently evident to the game player too, and adversely affected gameplay ("north" would be equivalent to "northeast").
Hence, Woods added the five-letter limit notes to Crowther's original game instructions.
The PDP-10 also implemented application checkpointing which allows saving and restoring of the state of the entire program, instead of a more traditional save file. Both these features made it difficult to directly port the code to other architectures.
One of the first efforts to port the code was by Jim Gillogly of the RAND Corporation in 1977. Gillogly, with agreement from Crowther and Woods, spent several weeks porting the code to C to run on the more generic Unix architecture. It can be found as part of the BSD Operating Systems distributions, or as part of the "bsdgames" package under most Linux distributions, under the command name "adventure". The game was also ported to Prime Computer's super-mini running PRIMOS in the late 1970s, utilizing FORTRAN IV, and to IBM mainframes running VM/CMS in late 1978, utilizing PL/I. In 1978, Chris Eisnaugle and Dan Blumenfeld, both high school students at the time, replicated the entire 350-point version of the game by coding a functional equivalent in HP Time-Shared BASIC for a Hewlett-Packard 2000C minicomputer. The gameplay and text content were identical to the original by Crowther and Woods. In the late 1970s, a freeware Commodore PET version was produced by Jim Butterfield; some years later this version was ported to the Commodore 64. Microsoft also released versions of "Adventure" in 1979 for the Apple II Plus and TRS-80 computers.
The Software Toolworks in 1981 released "The Original Adventure". Endorsed by Crowther and Woods, it was the only version for which they received royalties. Microsoft released "Adventure" in 1981 with its initial version of MS-DOS 1.0 as a launch title for the IBM PC, making it the first game available for the new computer. It was released on a single-sided 5 inch disk, required 32K RAM, and booted directly from the disk; it could not be opened from DOS. Microsoft's "Adventure" contained 130 rooms, 15 treasures, 40 useful objects and 12 problems to be solved. The progress of two games could be saved on a diskette. Later versions of the game moved away from general purpose programming languages such as C or Fortran and were instead written for special interactive fiction engines, such as Infocom's Z-machine.
In addition to strict ports of the game, variations began to appear, typically denoted by the maximum number of points one could score in the game; the original version by Crowther and Woods had a maximum of 350 points. Russel Dalenberg's Adventure Family Tree page provides the best (though still incomplete) summary of different versions and their relationships.
A generic version of the game was developed in 1981 by Graham Thomson for the ZX-81 as the "Adventure-writing kit". This stripped-down version had space for 50 rooms and 15 objects and was designed to allow the aspiring coder to modify the game and thus personalize it. The game's code was published in April 1982.
Dave Platt's influential 550-point version (released in 1984) was innovative in a number of ways. It broke away from coding the game directly in a programming language such as FORTRAN or C. Instead, Platt developed A-code – a language for adventure programming – and wrote his extended version in that language. The A-code source was pre-processed by a FORTRAN 77 (F77) "munger" program, which translated A-code into a text database and a tokenized pseudo-binary. These were then distributed together with a generic A-code F77 "executive", also written in F77, which effectively "ran" the tokenized pseudo-binary. Platt's version was also notable for providing a randomized variety of responses when informing the player that, for example, there was no exit in the nominated direction, introducing a number of rare "cameo" events, and committing some outrageous puns. Dave Platt's 550-point version of "Colossal Cave" – perhaps the most famous variant of this game other than the original, itself a jumping-off point for many other versions including Michael Goetz's 581 point CP/M version – included a long extension on the other side of the Volcano View. Eventually, the player descends into a maze of catacombs and a "fake Y2". If the player says "plugh" here the player is transported to a "Precarious Chair" suspended in midair above the molten lava. (The 581-point version was on SIGM011 from the CP/M Users Group, 1984.)
In 2017, Eric S. Raymond received permission from Crowther and Woods to release the source code for a forward port of their last version of the game dating from 1995. Raymond refers to this port as "Open Adventure", but it uses the original six-character name for the executable in order to avoid colliding with the BSD port.
The game has even been implemented in an ESP32 to connect directly to an ASR33 teletype to allow the game to be played stand alone on an antique teletype.
Critical analysis.
Graham Nelson's Inform Designer's Manual presents "Advent" as the pioneer of the three-part structure typical of 1980s adventure games; he identifies the "prologue" with the aboveground region of the game "whose presence lends a much greater sense of claustrophobia and depth to the underground bulk of the game", the transition to the middle game as the "passage from the mundane to the fantastical", and the endgame or "Master Game".
Dennis Jerz, among other cavers, has explored the Mammoth Cave system against Crowther's original layout for the game, and they believe that much of Crowther's map and descriptions in the game matched well with the natural Colossal Cave as it had been in the 1970s at the time that Crowther would have surveyed it. Many of the rooms are named based on caving jargon used for marking survey points which Crowther would have used in his surveys. In-game elements such as the small house at the start of the game and grates separating some rooms represented features that had been in place by the Park Service but since removed. Other natural elements such as a narrow cobble-strewn crawlway leading from the Bedquilt Cave to the Colossal Cave also matched consistency with the in-game locations. Woods' expansion would add new features that were not part of the natural caves, as he had never visited the park.
Influence.
"Colossal Cave Adventure" is considered one of video gaming's most influential titles. Dave Lebling said that when it arrived at MIT's Laboratory for Computer Science, "For a couple of weeks, dozens of people were playing the game and feeding each other clues ... Everyone was asking you in the hallway if you had gotten past the snake yet." The game is generally the first known example of interactive fiction and established conventions that are standard in interactive fiction titles today, such as the use of shortened cardinal directions for commands like "e" for "east". "Colossal Cave Adventure" directly inspired the creation of the adventure game genre. Games such as "Adventureland" by Scott Adams of Adventure International, "Zork" by the team of Lebling, Marc Blank, Tim Anderson, Bruce Daniels, and Albert Vezza of Infocom, and "Mystery House" by Roberta and Ken Williams of Sierra Entertainment were all directly influenced by "Colossal Cave Adventure", and these companies would go on to become key innovators for the early adventure game genre.
As described by Matt Barton in "Dungeons and Desktops: The History of Computer Role-Playing Games", "Colossal Cave Adventure" demonstrated the "creation of a virtual world and the means to explore it", and the inclusion of monsters and simplified combat. For this, it is considered the precursor of computer role-playing games. Glenn Wichman and Michael Toy state "Adventure" as an influence for their game "Rogue" in 1980, which would go on to become the namesake of the roguelike genre.
"Adventure" also inspired the development of online multiplayer games like MUDs, the precursors of the modern-day MMORPG. The Atari 2600 video game "Adventure" was an attempt to create a graphical version of "Adventure", and itself became the first known example of an action-adventure game and introduced the fantasy genre to video game consoles. The "Carmen Sandiego" series, one of the first educational games, was inspired by transforming the caverns of "Colossal Cave Adventure" into a globe-spanning clue-and-treasure hunt.
Memorable words and phrases.
Due to its influence, a number of words and phrases used in "Adventure" have become recurring concepts in later games.
Xyzzy.
"Xyzzy" is a magic word that teleports the player between two locations ("inside building" and the "debris room"). Entering the command from other locations produces the disappointing response "Nothing happens." As an in-joke tribute to "Adventure", many later computer programs (not only games but also applications) include a hidden "xyzzy" command – the results of which range from the humorous to the straightforward. Crowther stated that for its purpose in the game, "magic words should look queer, and yet somehow be pronounceable", leading him to select "xyzzy". The meaning and origin of the term are unclear, but Crowther has said "I made it up out of whole cloth just for the game", and offered that as he had been considering working at Xerox at the time, he focused on a word starting with X.
Maze of twisty little passages.
In Crowther's original version of "Adventure", he created a maze where each of ten room descriptions was exactly the same; codice_1
The layout of this "all alike" maze was fixed, so the player would have to figure out how to map the maze. One method would be to drop objects in the rooms to act as landmarks, enabling one to map the section on paper. Woods' version added a second maze, where the description of each of eleven rooms was similar but subtly different.
For example, codice_2 and codice_3 The layout was still fixed but the player did not have to drop inventory objects to map the maze. Instead, this "all different" maze required the player to recognize the wording changes to find maze exits and its solution. Don Woods was doing doctoral research in graph algorithms, and he designed this maze as (almost) a complete graph, with two exceptions important to gameplay.
The phrase "you are in a maze of twisty little passages, all alike" has become memorialized and popularized in the hacker culture, where "passages" may be replaced with a different word, as the situation warrants. This phrase came to signify a situation when whatever action is taken does not change the result. The line was used by Nick Montfort in the title for his book about the history of interactive fiction, "Twisty Little Passages: An Approach To Interactive Fiction".
Plugh.
When the player arrives at a location known as "Y2", the player may (with 25% probability) receive the message "A hollow voice says 'PLUGH'." This magic word takes the player between the rooms "inside building" and "Y2". Some other games recognize "PLUGH" and will respond to it, usually by making a joke. The adventure game "Prisoner 2" contained a cavern with the word "PLUGH" written on the wall; if the player typed this word into the command parser, he was sent back to his starting point. The TRS-80 adventure game "Haunted House" – one of the few commercial adventure games playable with only 4K of RAM – "requires" the player to type PLUGH to enter the haunted house. If the player types PLUGH inside the haunted house, the game replies, "Sorry, only one PLUGH per customer." Another TRS-80 game, "Bedlam", replies to PLUGH with "You got better."
Plugh.com gives further historical background to the name, allegedly by Don Woods.
In popular culture.
The game "Kentucky Route Zero"'s third act draws direct inspiration from this game, as well as Crowther's career in caving. The act shows a computer simulation set up inside of a cave, which is itself depicting a massive cave system.
Though not mentioned by name, "Colossal Cave Adventure" is described in Tracy Kidder's 1981 non-fiction book "The Soul of a New Machine", alluding to several of the location names from the game.
The documentary "Get Lamp" on the history of text adventure games is named in part for one of the first objects the player encounters (the first is the lamp, the second is water) and must carry to solve "Colossal Cave Adventure".
"Colossal Cave Adventure" is a key plot point in season 1 episode 5 of the AMC TV series, "Halt and Catch Fire", a period drama taking place in the early days of the personal computing revolution. The chief software designer uses the game as a competency test to determine which programmers will remain on the team. Those who hack the code and find the backdoors are retained. As a tie-in, a fully playable version of the game (augmented with player hints and "hidden" artwork revealed when certain locations are visited) was made available on the show's official website. 
The point-and-click adventure "Thimbleweed Park" references a successor called "Colossal Cave Adventure 2" in the plot.
As of 1 May 2019, Colossal Cave Adventure was officially inducted into the World Video Game Hall of Fame along with Microsoft Solitaire, Mortal Kombat, and Super Mario Kart.