Skip to main content

File names and buffers

Data · Routines · Address index

The names of item, level, saved-game, dialogue and transfer files, file slots, shared buffers and file-error messages. The data page explains how the entries are written.

DS:0x1b1e–DS:0x1cc0 — Ending tables​

  • Layout: 0x1b1e word; 0x1b20 word; 0x1b22 21 far pointers to animation lists of 11-byte records; 0x1b76 13 far pointers to shape definitions, one per scene (null for scenes without shapes); 0x1baa 13 far pointers to the picture names that follow, DRAGON1.CPS (0x1bfc) to THANKS.CPS; 0x1bde far pointer and 0x1be2 word; 0x1be4 six (x, y) word pairs
  • Role: The tables of the ending. 0x1b1e is the skip flag: the ending clears it at six places and every step tests it, but no instruction stores a nonzero value in it, so it stays 0 (poll during a wait). 0x1b20 is set to 0 at the start and to 1 before the credits and never read. 0x1bde and 0x1be2 are the target palette and rate of the delayed palette fade. 0x1be4 gives the positions of the six portraits on the last picture: (80, 80), (208, 80), (80, 144), (208, 144), (144, 80), (144, 144).
  • Comparative source: REF-SCUMM-012, DarkMoonEngine::seq_playFinale.
  • Used by: Images, palettes and fonts, Decoration, door and monster images, Dungeon graphics, Scenes and sequence pictures

DS:0x1016, DS:0x101f — Item file names​

DS:0x12e6 — DCR file name format​

DS:0x131d, DS:0x1325, DS:0x132b — INF file name parts​

  • Layout: strings
  • Role: %s%d.%s, LEVEL and INF, combined into LEVEL<n>.INF by the INF level loader.
  • Used by: —

DS:0x139c–DS:0x1404 — Saved-game and level-record file names​

DS:0x158a, DS:0x162e, DS:0x1646, DS:0x1667, DS:0x166f — Dialogue and sequence file names​

DS:0x1758, DS:0x1764, DS:0x1770 — Party transfer file names​

DS:0xd0ac — Shared buffer​

DS:0xf02c — File slots​

  • Layout: 10 words; 0x3fff marks a free slot
  • Role: The files the game has open. 0x2ea8d frees them all at the start.
  • Used by: Resident files

DS:0xf16e — Runtime file name​

  • Layout: string buffer
  • Role: File name built at run time by each of its users: LEVEL<n>.INF in the INF level loader, EOBDATA<n>.SAV or FINAL.SAV in the save writer and reader, and the VCN name in 0x4811e.
  • Used by: —

DS:0x6d44 — Stored VCN name​

DS:0x5e3a — File-error messages​

  • Layout: 19 far pointers to zero-terminated strings (DS:0x5e8e–0x6111), then the disk request at DS:0x6118
  • Role: Messages of the file helpers, numbered by the kind argument of the disk prompt and the fatal file error: 0 could not create a file, 1 illegal open mode, 2 could not find a file, 3 too many files open, 4–7 a close, read, write or seek on an unopened file, 8 an illegal seek origin, 9 a write to a resident file, 10 an unknown resident file, 11 exiting with open files, 12 the fatal disk error, 13–17 errors of the resident-file table, which lists no file. DS:0x6118 is "Insert the disk containing '%s' in any drive.", added for kinds 0 and 2.
  • Used by: From files to the game › When a file is missing, Texts

DS:0x61f4 — Drive-search switch​

  • Layout: byte, 1 in the executable image
  • Role: While it is nonzero, the file search looks for a missing file on the other drives. Only the slot-list refresh changes it: it clears it around its scan of the save files through 0x2f2cc (store at 0x2f2cf) and sets it again through 0x2f2d6 (store at 0x2f2d9).
  • Used by:

DS:0xf042 — Last drive​

  • Layout: byte
  • Role: Number of the last drive, set at start-up from DOS (INT 21h functions 19h and 0Eh, 0x32632–0x3265f); the file search walks the drives from it down to A:.
  • Used by: