Twin Kingdom Valley

Last updated
Twin Kingdom Valley
TwinKingdomValleyElectron.jpg
Developer(s) Trevor Hall
Publisher(s) Bug-Byte
Platform(s) Acorn Electron, BBC Micro, Commodore 16, Commodore 64, ZX Spectrum
Release 1983
Genre(s) Interactive fiction
Mode(s) Single-player

Twin Kingdom Valley is a text adventure game with animated pictures (on most formats)[ clarification needed ] for the BBC Micro, Acorn Electron, Commodore 64, Commodore 16, and ZX Spectrum. It was released in 1983 by Bug-Byte.

Contents

Gameplay

Twin Kingdom Valley is a work of interactive fiction where the player enters commands such as "take jug" at a command prompt and is told the outcome of their move ("I have it now"). Each such command takes up one unit of time, during which other non-player characters will also move and take actions.

It was one of the first text adventure games to have active non-player characters. [1] The characters are interactive, and have their own personalities: some are friendly, and will follow and defend the player, while others are hostile. Witches and kings are complex characters, whereas gorillas and trolls are simpler. Battle sequences have additional features including weapons which can be dropped, broken, thrown or taken away by enemies.

Plot

The main character of this game, referred to as "you" by the game engine, is a treasure hunter. [2] The player starts the game at the southern edge of the forest kingdom, with few possessions. An early encounter with the innkeeper of The Sword Inn may persuade the player to rent a small log cabin from him. In the cabin are some meager supplies, such as a plain jug.

To progress through the game, the player must determine which characters to regard as friends, and which as foes. Some characters, such as a gorilla who attacks the player with a wooden club, are clearly presented as foes, while others are ambiguous.

There are two kingdoms - a forest and a desert - separated by a deep canyon. Each kingdom is ruled by a king, and the kings do not get along with one another. The player is told that the situation has got worse recently, and a royal from the forest kingdom is missing, the crime being attributed to the desert king. With two rich kingdoms at war, it is suggested that the player could take advantage of this and loot treasure from both sides. As the game progresses, the player finds it a challenge to transport spoils back to the log cabin, and is forced at times to choose between carrying a treasure and carrying a weapon, both types of object being at risk of theft if left unguarded.

The plot develops over time. In the original BBC Micro game, there were a limited number of locations and graphics. Some additions appear in the C64 version, though the plot is largely the same. The modern smartphone edition of the game adds more locations and some new plot twists.

Development

Concept

The game was inspired by the original Adventure by Will Crowther. [3] The original game engine was written in 6502 assembly language. The game was then ported to Z80 for the Spectrum. The newer versions (for Commodore 64 and Spectrum) have an extended game. The game set out to add a level of realism through the addition of images, and complex characters.

The beginnings of the game were more of a peer pressure challenge than a commercial venture. At that time, access to the "massive machines" (by the standards of the day) needed to run the original adventure were limited. The thought was: surely this can be done on a home computer, somehow. The slowness of high level language code (Basic) on home systems ruled that out as a path, and there was no access to a FORTRAN compiler at the time. Few people had run the original, and (having graduated) those students who had access to university equipment capable of running the game had lost that privileged access. The elements resembled the original, with a road, a building (containing useful items, such as keys and a lamp) being repeated. The building is in the forest, with a spring nearby, but beyond this teaser that it is a kind of clone, the similarity ends. The plan changed to "why copy, when you can do better".

Rather than just modelling a cave, the challenge was to model a larger world, with many above ground, underground, inside and outside locations. Twin Kingdom Valley features 175 rooms. [4]

A somewhat medieval era was chosen for the game, allowing elements of mysticism. All combat was designed as basic hand-to-hand style, with the player and other characters taking turns to trade blows. Turns are always initiated by the player's typing, rather than occurring in real time. If the player attempts to flee from combat, the opponent is permitted one attack before the player moves. The player's behavior is modelled in the same manner as the characters. Like similar games, characters have various limits, such as their maximum health and rate of healing, and the carrying capacity.

Graphics

A major section of the software is a custom graphics language, which is an early scalable vector graphics format. Hundreds of images of objects and locations are drawn in the game using this custom tool. Perspective of a limited kind is achieved by permitting images to be drawn scaled down within another image. For example, a castle model would be designed for close up view, but could also be drawn as a subroutine for a distant castle in a desert. The graphics speed was about 10 polygons per second, so the game could not afford to write background polygons and over fill. Images are just created by flood fills, such that each screen pixels is filled only once. A modern PC (using an emulator) can paint these pictures instantly, but the original game owners would need to wait three or four seconds for the screen to paint.

The graphics commands had to be heavily compressed due to the limited memory space budget.

To draw and fill an outline, 3 basic commands were needed: Move, Draw, Fill. A move (to start of shape) followed by drawing to each point on the outline, until the shape is closed, then filling within the shape. Draw and fill need a color for the line. All of Move Draw and Fill need a coordinate. To decode this efficiently, just 2 bits are needed to resolve "Move, Draw, Fill, "any other instruction" in an assembly language. [5] An extra bit determines if the command has absolute screen coordinates, or a relative position. 3 bits give a choice of 8 colors, and finally 10 bits give two 5 bit x,y coordinates.

The other commands (not needing coordinates) included: calling a subroutine, ending a subroutine, drawing a circular arc (center at the last moved coordinate) etc. Complex images, such as a cabin made of many logs, use a loop instruction, similar to for loop in C, with a constant loop limit. The assembly language has no concept of variables, and no branching instructions.

Game engine

The game has several micro databases of information, representing the locations, objects which can be used, various creatures, and other data. The game engine runs a simulated world for these items. A small AI module allows the non-player characters to make decisions. [6]

The location engine has some features to save memory. In most locations there are just a few words, but a detailed (bit packed) "exit database" is interpreted to make longer descriptions. These descriptions can vary as bits are set and cleared for locked and unlocked doors. A location with about eight lines of text describing it may be less than 30 bytes of data. Words used in the game location database are stored as a single byte per word, which look up into a 256 word list, and as a result many words are reused several times. For example, "You are by a babbling brook, North you can see a stream, South you can see a road, North West is a deep river". The words "You are" are added by the game engine. "by a babbling brook" is just 4 bytes of data, a 5th byte encodes the length (4) of the message in words. The location has 3 exits, which are coded as 2 or 3 bytes per exit. Byte 1 has the compass direction plus up or down (6 bits for N,S,E,W,U,D). An additional bit marks special exits such as locked doors. An additional byte then defines various bits for locked/unlocked or "can see through, cannot see through" etc. Them comes a byte for the destination. The first word of the destination is then skipped, so: if North led to "By a stream", the word "By" is omitted, and the words "you can see" are added, giving "North you can see a stream" using just 2 bytes.

All of this compression was needed to fit the game within the 32k limit or the original BBC Micro system. 10k is lost as the screen buffer, so the game memory is down to 22k from the start. With some of the memory needed for variable space or stack, the available code are in such as system is nearer to 20k. If the game had 200 locations at 30 bytes per location, this would be 6k. Even this would leave almost no space for game code, especially graphics. The original versions of the game had fewer than 200 unique locations, for this reason. There are roughly 180 locations in early editions (such as that of the BBC Micro), and 190 in later editions (such as the Commodore 64 version). Other game tables (such as those for creatures or objects) are much smaller.

The game has a small data reset block, which re-locks doors and other objects when the player starts a new game. In later versions (such as C64), extra memory allowed for some longer messages in plain text for special game events and puzzles.

Because creatures can hold objects, all creatures are treated as special locations by the game engine. An object has a single byte location which can be a room or a creature, and all locations above 200 are reserved for creatures, or other special location codes (such as "broken").

Continued development

The game was in active development again in 2006, due to the availability of new platforms. The game engine has been ported, from the original 6502, into Java, with some game design tools in C#.

Reception

Reviews were generally positive. The World of Spectrum link has many screen captures of magazine reviews of the game.

Here are the ratings given by Crash Magazine, for the ZX Spectrum version:

That review comments on the peculiarities which occur when porting games from the BBC micro or C64 to the ZX Spectrum. The original BBC version had been reported by the maker, Bug Byte, as a "No. 1 hit" by one magazine, reportedly based on sales figures. There is little or no information available on how magazines at the time compiled such charts, but the sales were clearly significant enough for the publisher to request the various ports listed, and to run many full page adverts for the game.

Letters were sent to the game publisher, in a time before "internet review systems" had been created. These are long lost, but did include generally positive comments. Most notable among them was a letter from the father of a blind child, who was able to play the game, thanks to the included speech synthesizer support.[ citation needed ]

Related Research Articles

<span class="mw-page-title-main">Commodore 64</span> 8-bit home computer introduced in 1982

The Commodore 64, also known as the C64, is an 8-bit home computer introduced in January 1982 by Commodore International. It has been listed in the Guinness World Records as the highest-selling single computer model of all time, with independent estimates placing the number sold between 12.5 and 17 million units. Volume production started in early 1982, marketing in August for US$595. Preceded by the VIC-20 and Commodore PET, the C64 took its name from its 64 kilobytes(65,536 bytes) of RAM. With support for multicolor sprites and a custom chip for waveform generation, the C64 could create superior visuals and audio compared to systems without such custom hardware.

In computer architecture, 8-bit integers or other data units are those that are 8 bits wide. Also, 8-bit central processing unit (CPU) and arithmetic logic unit (ALU) architectures are those that are based on registers or data buses of that size. Memory addresses for 8-bit CPUs are generally larger than 8-bit, usually 16-bit. 8-bit microcomputers are microcomputers that use 8-bit microprocessors.

<span class="mw-page-title-main">VIC-20</span> 1981 home computer by Commodore

The VIC-20 is an 8-bit home computer that was sold by Commodore Business Machines. The VIC-20 was announced in 1980, roughly three years after Commodore's first personal computer, the PET. The VIC-20 was the first computer of any description to sell one million units. It was described as "one of the first anti-spectatorial, non-esoteric computers by design...no longer relegated to hobbyist/enthusiasts or those with money, the computer Commodore developed was the computer of the future."

<span class="mw-page-title-main">PEEK and POKE</span> Commands in some high-level programming languages

In computing, PEEK and POKE are commands used in some high-level programming languages for accessing the contents of a specific memory cell referenced by its memory address. PEEK gets the byte located at the specified memory address. POKE sets the memory byte at the specified address. These commands originated with machine code monitors such as the DECsystem-10 monitor; these commands are particularly associated with the BASIC programming language, though some other languages such as Pascal and COMAL also have these commands. These commands are comparable in their roles to pointers in the C language and some other programming languages.

Commodore BASIC, also known as PET BASIC or CBM-BASIC, is the dialect of the BASIC programming language used in Commodore International's 8-bit home computer line, stretching from the PET (1977) to the Commodore 128 (1985).

<span class="mw-page-title-main">MOS Technology VIC-II</span> Video microchip in the Commodore 64 and C128 home computers

The VIC-II, specifically known as the MOS Technology 6567/6566/8562/8564, 6569/8565/8566 (PAL), is the microchip tasked with generating Y/C video signals and DRAM refresh signals in the Commodore 64 and Commodore 128 home computers.

<i>Valhalla</i> (video game) 1983 video game

Valhalla is a text adventure with graphics published in 1983 by the British studio Legend for the ZX Spectrum. It reached number one in the UK sales charts. The Commodore 64 version of the game was released in 1984 and reached number five.

Thalamus Ltd was a British computer game developer that published titles for a number of 8-bit and 16-bit platforms during the late 1980s and early 1990s.

<i>Exile</i> (1988 video game) Single-player action-adventure video game first published in 1988

Exile is a single-player action-adventure video game originally published for the BBC Micro and Acorn Electron in 1988 by Superior Software and later ported to the Commodore 64, Amiga, CD32 and Atari ST, all published by Audiogenic. The game was designed and programmed by Peter Irvin and Jeremy Smith. It is often cited as one of the earliest examples of a Metroidvania game and featured "realistic gravity, inertia and object mass years before players understood the concept of a physics engine... an astounding level of AI, stealth-based gameplay, a logical ecosystem governing the world's creatures and a teleportation mechanic that feels startlingly like a predecessor to Portal".

<i>The Hobbit</i> (1982 video game) 1982 video game

The Hobbit is an illustrated text adventure computer game released in 1982 for the ZX Spectrum home computer and based on the 1937 book The Hobbit, by J. R. R. Tolkien. It was developed at Beam Software by Philip Mitchell and Veronika Megler and published by Melbourne House. It was later converted to most home computers available at the time including the Commodore 64, BBC Micro, and Oric computers. By arrangement with the book publishers, a copy of the book was included with each game sold.

<span class="mw-page-title-main">Micro Power</span>

Micro Power was a British company established in the early 1980s by former accountant Bob Simpson. The company was best known as a video game publisher, originally under the name Program Power. It also sold many types of computer hardware and software through its Leeds 'showroom' or via mail order.

<i>Bone Cruncher</i> 1987 video game

Bone Cruncher is a puzzle video game for the Acorn Electron, BBC Micro, and Commodore 64 first published by Superior Software in 1987. It uses the "rocks and diamonds" mechanics of Boulder Dash. An Amiga version was released in 1988.

Super Expander 64 is a cartridge-based extension to the built in BASIC interpreter of Commodore 64 home computer. It was published by Commodore Business Machines in 1983. The built-in BASIC of the C64 was adapted from the PET and VIC 20, and the language does not have direct support for the system's sound and graphics hardware. Super Expander 64 adds functions for drawing graphics, using sprites, reading joysticks, playing audio, and other features.

<i>Questprobe featuring The Hulk</i> 1984 video game

Questprobe featuring The Hulk is a 1984 graphic adventure video game developed and published by Adventure International in collaboration with Marvel Comics. It is the first entry in Questprobe, an intended series of graphic adventure games that only released three installments before the developer's bankruptcy. The game's narrative follows the Marvel superhero Hulk and his human alter-ego Bruce Banner, who must explore the mysterious lair of the Chief Examiner. The graphics and story outline were created by Marvel artists and writers. Critical reception was generally positive, with much of the praise going to the visuals. Reactions to the gameplay were mixed, especially upon the game's budget re-release, by which time it was considered dated.

Fantasia Diamond is a text adventure game by Kim Topley and published by Hewson Consultants. It was released in 1984 for the Amstrad CPC, Acorn Electron, ZX Spectrum and BBC Micro home computers. Unusually for Hewson, it was not released on the Commodore 64 with the game's author stating when asked "The answer to your question is simply that I didn’t own a C64 at the time".

<i>Judge Dredd</i> (1986 video game) 1986 video game

Judge Dredd is a platform shoot 'em up video game based on the character of the same name. It was developed by Beam Software and published by Melbourne House. It was released in Europe in 1986, for Commodore 64 and ZX Spectrum.

<i>Judge Dredd</i> (1991 video game) 1991 video game

Judge Dredd is a 1991 platform shoot 'em up video game based on the character of the same name. It was developed by Random Access and published by Virgin Mastertronic. It was released in Europe in 1991, for the Amiga, Atari ST, Commodore 64, and ZX Spectrum. Critics found the gameplay repetitive.

<i>Tom & Jerry</i> (1989 video game) 1989 video game

Tom & Jerry is a 1989 platform game developed and published by German company Magic Bytes. It is the first video game based on the cartoon of the same name, and was released in the United States and Europe, for Amiga, Atari ST, and Commodore 64 computers.

<i>Pink Panther</i> (video game) 1988 video game

Pink Panther is a 1988 video game based on the character of the same name. It was developed by German company Magic Bytes and published by Gremlin Graphics. It was released in Europe for Amiga, Amstrad CPC, Atari ST, Commodore 64, and ZX Spectrum. Pink Panther was criticized for its control and difficulty, although the Amiga and Atari ST versions received praise for their graphics.

References

  1. Gunness, Jacob (November 1999). "Interview Trevor". Classic Adventures Solution Archive. Retrieved 3 December 2013.
  2. "Twin Kingdom Valley" . Retrieved 2024-02-08.
  3. ":: CASA :: Interview Trevor".
  4. "Twin Kingdom cassette features 175 locations". Micro Adventurer. London: Sunshine Books. January 1984. p. 7.
  5. Gunness, Jacob (August 2006). "Interview Trevor 2". Classic Adventures Solution Archive: Twin Kingdom Valley - on the move. Retrieved 3 December 2013.
  6. ":: CASA :: Interview Trevor".