Data outside the data segment
Data · Routines · Address index
Tables of the resident image that lie outside the data segment: sound driver state, button lists, party-transfer tables and other tables. The data page explains how the entries are written.
Some tables lie in the resident image but outside the data segment. They are
located by their file offset, and their anchors start with p-.
Sound driver 1 keeps its variables in its own code segment, 0x1000:
there, cs:x is analysis address 0x10000 + x and file offset x + 0x3200.
Physical 0x3450 — Music marker
- Layout: byte; analysis address
0x10250(cs:0x250of driver 1); 0 in the file - Role: The last value set by command
0xc7of an ADL program, written by run the channels and returned by0x10251. The introduction and the ending wait for it to reach each of their markers. - Used by: Playing AdLib programs › Music markers, The introduction › Music and sounds, The ending › Music and sounds
Physical 0x34c6 — Sound data buffer
- Layout:
0x3b10= 15,120 bytes; analysis address0x102c6(cs:0x2c6) - Role: Receives the part of the ADL file after the sound-effect
table (load the sound file). Its first 500 words,
the program and instrument pointers, are made absolute by
0x102aa; the instrument table starts atcs:0x4ba. - Comparative source: REF-MW-015.
- Used by: AdLib music and sounds (ADL) › Reading the file, PC speaker and Tandy sounds (SND)
Physical 0x75fd — Sound request queue
- Layout: 16 bytes, analysis address
0x143fd(cs:0x43fd); read position wordcs:0x43fb, write position wordcs:0x43f9 - Role: Program numbers waiting to start, written by
queue a program and read on each tick by
0x148a6. Each number is written as a word, so the byte after the last slot, the first byte of channel 0's state, is also written (ANOMALY-97). - Used by: Anomalies and bugs
Physical 0x760d — Channel states
- Layout: 10 ×
0x43bytes from analysis address0x1440d(cs:0x440d), one per channel; the table of their addresses is atcs:0x46ab - Role: The state of each driver channel: byte 0 a level offset set by
commands
0xacand0xad;0x03the command pointer;0x05the step counter;0x06the repeat counter;0x07the base octave;0x08the priority;0x09the call depth and0x0a–0x11the return addresses of command0x85(0x86returns);0x12the base note;0x13–0x16the slide (rate, counter, step word);0x17–0x1fthe vibrato (step word, depth, half-period count and reload, delay reload, rate, counter, delay);0x20and0x30two more level offsets;0x21the note-off point;0x24the base frequency;0x25and0x26the tempo and its counter;0x27and0x28the last values written to registers0xa0and0xb0;0x29and0x2bthe two effect slots;0x2dthe note-off fraction;0x2eand0x2fthe operator levels and0x31the connection bit;0x32–0x34the velocity shifts and the last velocity;0x35the note spacing;0x36the duration randomness mask;0x39–0x3fa register cycle (rate, counter, reload, index, register, table address);0x40the tempo reset;0x41the last note byte;0x42the pitch bend. Bytes 1, 2,0x22,0x23,0x37and0x38are never accessed. The call depth is not bounded: a fifth nested call overwrites byte0x12; no original sound file uses command0x85. Bytes 3 to0x42are cleared when a program starts on the channel. - Comparative source: REF-SCUMM-012,
AdLibDriver::Channel. - Used by:
Physical 0x78c8, 0x73d4 — AdLib frequency and pitch bend tables
- Layout: 12 words; 14 words, then 14 × 32 bytes
- Role: In the segment of sound driver 1 (
cs:0x46c8andcs:0x41d4). The first is the 10-bit frequency number of each semitone, from0x134to0x246, read by the note routine. The second holds the driver offsets0x41f0to0x4390of fourteen 32-byte pitch bend tables (file0x73f0onwards), chosen by the note's low four bits (plus two for an upward bend) and indexed by the bend; nothing bounds either index (ANOMALY-124). - Used by: How an AdLib note sounds › How a note sounds
Physical 0x8a0e — ADL command table
- Layout: 74 words, analysis address
0x1580e(cs:0x580e), for commands0x80to0xc9; the next word, atcs:0x58a2, begins another table - Role: Handler addresses of the ADL commands,
used by run the channels. Twenty entries point to
the stop handler
0x14b8b. The bound check accepts indices up to0x70, so the words after the table also serve as handlers for bytes0xcato0xf0(ANOMALY-99). - Comparative source: REF-SCUMM-012,
AdLibDriver::_parserOpcodeTable. - Used by: AdLib music and sounds (ADL), Anomalies and bugs
Physical 0x27290 — Teleporter sparkle points
- Layout: 6 sets × 13 pairs of signed bytes; analysis address
0x34090(segment reached through operand0x250of the overlay segment table) - Role: The 13 (x, y) points of each sparkle layer: sets 0–1 one step
ahead, 2–3 two steps ahead, 4–5 three steps ahead, drawn by
0x3f311. - Comparative source: REF-SCUMM-016,
_teleporterShapeCoords. - Used by:
File offsets 0x27330–0x27558 — Party creation buttons
- Layout: three tables reached through operands
0x258,0x260and0x268of the overlay segment table.0x27330: 41 button definitions of 8 bytes (x in 8-pixel columns, y, width, height, key number, three zero bytes).0x27480: 4-byte rectangles (column, y, width in columns, height) of button pictures inCHARGENB, normal then pressed.0x274c0: 17 drawing records of 9 bytes (label column, y, width in columns and height inCHARGENB; label offset x, y; picture index; destination column, y) - Role: The buttons of the party creation screen.
Definitions 0–3 are the four boxes (keys F1 to F4), 4 PLAY (key P), 5 OK,
6 DELETE, 7 BACK at the place of OK, 8–20 the thirteen menu lines,
21–22 the portrait arrows, 23–26 the four portraits, 27–30 REROLL, MODIFY,
FACES and KEEP, 31–37 the fields of the modify screen and 38–40
+,−and OK. Build a button list reads the definitions; draw a button the rectangles and drawing records, whose labels are cut once fromCHARGENB. - Comparative source: REF-SCUMM-017,
initButtonsFromListanddrawButton. - Used by:
File offsets 0x27560–0x275d9 — Starting armour records
- Layout: four lists at file offsets
0x27560,0x27590,0x275a0and0x275c0, reached through the far pointers ofDS:0x0af2(segments0x2436–0x243c). Each starts with a count word, whose low byte is read, followed by 12-byte records of two (template item, value, inventory slot) word triples; an item of −1 ends a record early. - Role: One record is chosen at random for each new character by starting status and items: list 0 Plate Mail, Scale Mail with a Shield, or Chainmail with a Shield; list 1 a Robe; list 2 Scale Mail or Chainmail with a Shield; list 3 Leather armor with a Shield, in two records with different values.
- Comparative source: REF-SCUMM-017,
finish(itemList0–itemList3). - Used by:
File offset 0x275e0 — Camp menu buttons
- Layout: 10-byte records, reached through operand
0x290of the overlay segment table: camp string of the label (byte), x (word), y, width, height (bytes), key number (word), flags (word: bit 0 draws a box, bit 1 lets the pointer highlight the button, bit 2 centres the label); 36 records read; the key of each definition, in order, is: R M P S none G E; L S D Q E; S B E; E, F1–F6; C E Space 1–6; Y N - Role: The buttons of the menu definitions, read by build and show a menu. For example records 32 and 33 are Yes (x 16, y 57, 32 × 14) and No (x 128) of the yes/no question. Record 31, a seventh spell-level tab, lies outside the range of the spell menu, which has six.
- Comparative source: REF-SCUMM-014,
GUI_EoB::initMenu(_menuButtonDefs). - Used by: Camp menus › The camp menu, Camp menu and spells › Menu tables
File offset 0x27820 — Protection answer words
- Layout: 50 zero-terminated lowercase words, one after the other, from
0x27820to0x2799c - Status: that these words are the answers of the
protection check
is inferred: the check reads records from segment
0x298, and the code that compares them was not traced further. - Role: A list of single words outside the data segment, inferred to be the expected answers to the protection question.
- Used by: Texts
File offset 0x279a0 — Non-player character presets
- Layout: six character records of
345 bytes,
0x279a0–0x281b5, reached through operand0x2a8of the overlay segment table (paragraph0x247a); data unrelated to characters follows them - Role: Copied into a free party slot by
initialize a preset, and read for their names by
the resurrection menu. In order: Insal, Calandra,
Shorn, San-raal, Tanglor and Amber. Every preset has
status_flags1, portrait −1 to −6 in order, first byte 0 and no spell slots or timers. Experience, the dwords at+0x29: Insal 27,354; Calandra 253,749; Shorn 137,008; San-raal 97,008; Tanglor 69,570 on two classes; Amber 64,230 on two classes.defense(+0x1f) is 10, Tanglor's 9.known_mage_spells(+0xd9) is0x096b4566for San-raal,0x00294566for Amber,0xfffffffffor Tanglor and 0 for the others. - Comparative source: REF-SCUMM-009,
initNpc. - Used by: Recruiting and dismissing characters › Recruiting and dismissing characters, Recruiting and dismissing characters, Characters of the game
File offsets 0x281c0–0x281fd — Dream frames
- Layout: four tables reached through operands
0x2b0to0x2c8of the overlay segment table: source columns (0, 20, 0, 20) at0x281c0, source rows (0, 0, 96, 96) at0x281d0and waits in ticks (12, 7, 7, 12) at0x281e0, one byte per frame; the frame order at0x281f0, 1 2 3 2 1 0 1 2 3 3 2 1 0, ended by0xff - Role: The animation of the dream sequence:
each frame draws one 160 × 96 quarter
of
DREAM, then waits; the 13 frames last 116 ticks. - Used by:
File offset 0x28200 — Spell conversion table of a party transfer
- Layout: 64 bytes, analysis address
0x35000, reached through operand0x2d0of the overlay segment table (paragraph0x2500) - Role: Maps a spell number of an Eye of the Beholder I party to a
spell of this game, 0 for none. Entries 1–25 serve the known mage spells (
0x4c216) and the value of mage scrolls; entries 26–49 the value of cleric scrolls plus 25 (convert an item). No index is checked. - Comparative source: REF-SCUMM-017,
TransferPartyWiz::convertStatsandconvertItem(_convertTable). - Used by: Transfer: spells and items
File offset 0x28240 — Experience caps of a party transfer
- Layout: six dwords, by base class (fighter, mage, cleric, thief,
paladin, ranger), right after the spell conversion table;
operand
0x2d8of the overlay segment table (paragraph0x2504) - Role: 999,999, 749,999, 899,999, 439,999, 899,999 and 899,999: the highest experience a transferred character keeps in a component of that base class (convert the characters).
- Comparative source: REF-SCUMM-017,
TransferPartyWiz::convertStats(_expTable). - Used by: Transferring a party from Eye of the Beholder I › Transferring a party from Eye of the Beholder I
File offsets 0x2c927–0x2cad6 — Party transfer questions
- Layout: four zero-terminated strings of the list at file offset
0x2c170, numbers 68 to 71:0x2c927,0x2ca27,0x2ca61,0x2ca95 - Role: Shown by read
EOBDATA.SAV, number 68 (0x4c174), and by transfer a party: the missing file, too few characters, too many characters and the warning about deleted items (0x4cf24,0x4cf48,0x4cf8b, all file offsets of overlay code). - Used by: Transferring a party from Eye of the Beholder I › Transferring a party from Eye of the Beholder I, Texts, Transfer: spells and items
File offset 0x2cc60 — Initial spell-definition table
- Layout: 25-byte entries; entries 0 and 33 are empty. Mage spells use
entries 1–32 and cleric spells entries 34–62: the code multiplies a spell's
number by 25 and adds 0 or
0x339(33 entries). - Role: Initial spell definitions.
The table is in paragraph
0x29a6, which the segment-table entry at file offset0x2dc58gives; overlay code reaches it through fixed-up segment0x738. Analysis address0x39a60. Every start and end routine in the initial table is resident code of segment0x13a7, at analysis addresses0x23a72–0x24e18(for instance Wall of Force0x24440, Disintegrate0x24595, True Seeing0x2467d); the timer parameters are four words at offset 0 of segments0x2995–0x29a4. Entry 9, Improved Identify (file offset0x2cd41), has flags0x0080and effect mask0x00000040, with none of the flags that apply a mask. Entry 64 (file offset0x2d2a0), named "mystic defense" (DS:0x2f50), has no start routine, flags0x004c, sound 91, effect mask0x00020000and timer parameters (1, 546, 0, 1); only a wand of value 5 casts it. Entries 63, 65 and 66 have empty names. The table has no bound check. - Used by: Potions, scrolls and wands, Lasting spell effects, Magic › How the game stores spells, Mage and cleric spells › Special entries, Spell definition › In brief, Wall references with built-in effects, Texts, Damage to a monster › Kinds that never occur, Kinds of damage dealt to a monster, Anomalies and bugs
File offset 0x2d370 — Horn sounds
- Layout: 4 bytes, 64 to 67, in segment
0x2a17of the program (analysis address0x3a170) - Role: The sound effect of a horn of value 1 to 4 (blow a horn); other values read outside the four bytes.
- Used by: Using items › Food and other uses, Sound effects, The item types