Dangerous Dave in the Haunted Mansion

From XentaxWiki
Jump to: navigation, search

Back to index


Game files

  • CTLPANEL.DD2 - user preferences file (key codes, sound/nosound and so on)
  • INTRO.DD2 - RLE compressed intro screen dump
  • LEVEL0x.DD2 - RLEW compressed levels files
  • PROGPIC.DD2 - HUFF compressed PIC file
  • S_CHUNK1.DD2 - HUFF compressed chunk file
  • S_CHUNK2.DD2 - HUFF compressed chunk file
  • S_DAVE.DD2 - HUFF compressed chunk file
  • S_FRANK.DD2 - HUFF compressed chunk file
  • S_MASTER.DD2 - HUFF compressed chunk file
  • STARPIC.DD2 - HUFF compressed PIC file
  • TEDLEVEL.DD2 - contains 1 byte - start level number (if used /LEVEL option)
  • title1.DD2 - PIC file HUFF compressed
  • title2.DD2 - PIC file HUFF compressed
  • DAVE.EXE - lzexe compressed

HUFF compressed file format

  1. Signature 4 bytes. Must be 0x48 0x55 0x46 0x46.
  2. Expanded size. 4 bytes.
  3. Huffman nodes table. 1020 bytes.
  4. Compressed data. (Unknown size before extract process ends).
  5. Arbitrary data. Simply ignored. (Any size).

RLEW compressed file format

RLEW is RLE comression by WORD, not BYTE. First four bytes are uncompressed file length. Next, goes compressed data. Every word in compressed source is copied to uncomressed destination except 0xfefe. This flag value designates special place: next follows two words: count and value. value is copied count times to destination.

PIC file format

PIC file simply is EGA mode 0xd screen dump. In this mode screen has resolution 320x200 pixels with 16 colors. This means that one pixel is 4-bits wide. Videomemory for this mode starts at 0xa0000. Entire screen uses 32000 bytes and broken onto 4 banks of 8000 bytes each. These banks are located in memory on after another, first starts at videomemory start (0xa0000). Each bank encodes single color plane. 16 colors are constructed of four banks. Intnsity, red, green and blue. 8 pixels are encoded by 4 bytes: first is taken from first byte and means intensity of pixel, second from second bank and means red part of color and so on. This way 4 bits with same number taken from bytes located at the same offset from each own bank together construct one pixel. So if you want to show PIC picture on EGA screen you simply copy it to videomemory without any conversion. To show such picture on screen which do not use color planes but encodes color with several bits placed one after another in memory you need to convert that picture. This can do function decode_mode_d. It accepts PIC picture buffer (32000 bytes) and returns color index array (64000 bytes). – Sorry for my english

  1. Signature 4 bytes. Must be 0x50 0x49 0x43 0x00.
  2. Picture width. 2 bytes.
  3. Picture height. 2 bytes.
  4. Picture data. 32000 bytes.