Telengard, published by Avalon Hill in 1982, is an early example of the dungeon crawl style of adventure game. If was published for a number of different computers including the Atari 8-bit systems which is the one that this page is about.






Atarimania - You can download the disk image of the game from this site, along with a copy of the instruction manual.

Telengard Information

Telengard Tribute Site

Disk Files

The disk image for Telengard contains the following files:

DOS.SYS, DUP.SYS - Atari DOS files
AUTORUN.SYS - Atari autorun file, starts TELEN.BAS
TELEN.BAS - Atari Basic game startup program
DSKTEL.BAS - Atari Basic main game program (older version)
DSKTELEN.BAS - Atari Basic main game program (newer version)
TELINI.DAT - Game constant data loaded by the main program
TELEN.SET - Redefined character set data
ALAN.PLR - Saved game

Basic Listing

This file contains a listing of the main game program that I have extensively commented to describe how the game works.

Basic Listing

Map Generation

One of the interesting parts of Telengard is the way it generates the dungeon map. The dungeon in the game is very large, it has 50 level and each level is 200 by 200 rooms. The dungeon is also the same every time you play so you can map it out as you go along. This is achieved by using a pseudo-random algorithm to generate the map. This results in a map that is complex enough to be interesting, but not so complex that it's unplayable.

This is the formula that is used to determine the appearance of each room:

XO = 1.6915
YO = 1.4278
ZO = 1.2462

q = x * XO + y * YO + z * ZO + x * YO + y * ZO + z * XO
hi = q And &HFF
q = x * y * ZO + y * z * XO + z * x * YO

If (q And 3) = 0 Then

q = (q / 4) And &HF
If q > 9 Then q = q - 9
hi = hi + q * 256

End If

XO, YO and ZO are constants
z = dungeon level
x,y = room position in level

hi describes the room as follows:

bits 0,1: Upper wall: 0,1 = nothing, 2 = door, 3 = wall
bits 2,3: Left wall: 0,1 = nothing, 2 = door, 3 = wall
bits 8-11: If not 0 then there is something special in the room

1 = Inn
2 = Pit
3 = Teleporter
4 = Stairway
5 = Alter
6 = Fountain
7 = Cube
8 = Throne
9 = Box

To view the entire map I created a VB.NET map generator program. This program required the Microsoft .NET Framework 2.0:

Map Viewer - Executable and source

[Home] [Site Map]

Dan Boris -