Contents

Technical Documentation - File Formats - Animations

Overview

In this document, the word "animation" refers to animated sequences –you may call them cutscenes or videos– like the introduction of a game. It does not refer to in-game animations (like creatures animations which are built dynamically by the program).

The file format described in this document is used in most versions of Dungeon Master, Chaos Strikes Back and Dungeon Master II. This documentation is based on the analysis of 30 different animations files listed in a table below.
However, the following games use other formats:

  • Dungeon Master for SNES (unknown format).
  • Chaos Strikes Back for Atari ST does not use this animation format but instead uses the Data File format to store the introduction data. The animation script is stored in a separate file named ANIMATE.SCR. See Technical Documentation - File Formats - Data Files and Technical Documentation - File Formats - Animation Script (ANIMATE.SCR).
  • Dungeon Master II for PC uses the Interplay MVE file format.
    In the animation files (FTL, INTRO, END, CREDITS), the first 100206 bytes are used by a DOS MVE player. The rest of the files (starting with the string "Interplay MVE File") store the .MVE files data. MVE2AVI is an MVE player/converter working under windows (it works fine with INTRO, END and CREDITS but not FTL).
    If you use the DOSBox emulator, you can rename the animation files to add the .exe extension and then use the following command line with the player built-in each file.
    ANIM.EXE [videomode] [HALF|BLEND|WIDE|HOLD|LOOP|NOABORT] [audio [track]]
    where:
    • 'videomode' is one of these: 640x400, 640x200, 640x480, 640x240, 800x600, 800x300, 1024x768, 1024x384, 1280x1024, 1280x512, 320x200, 320x350, 360x480, 320x240, 320x480, 640x160, 640x350, 640x175.
      During my tests under the dosbox emulator, all resolutions were not accepted. I don't know if it is a limitation of dosbox or if the animations cannot play in all resolutions.
    • 'audio' is one of these drivers: SB SBPro SBProMono SB16 SB16Mono PAS PASMono AdlibGold AdlibGoldMono Yamaha Microsoft MicrosoftMono AudioDrive AudioDriveMono SoundScape SoundScapeMono Gus GusMono GusMax GusMaxMono WaveJammer WaveJammerMono Tempocs TempocsMono.
    • 'track' is the track number (always 0 in Dungeon Master II animations).
    • half: will display only half of the images vertically
    • half2: will display only every other line vertically
    • blend
    • blend2
    • wide
    • hold: leave the last picture of the animation on screen (by default, the player will close).
    • loop: when the animation is finished it will automatically start playing again.
    • noabort: the user cannot stop the animation by pressing ESC.
    • dblbuf
  • Dungeon Master II for Macintosh: this version uses standard Apple QuickTime .moov files. Playing these videos on PC is a little tricky, you can find some background information about How to transfer QuickTime files between Macintosh and PC. You can extract the files from a Macintosh hard disk image. For each video, you need to extract the data fork (.mov file) and the resource fork (.qtr file) with a tool like HFVExplorer.

As you will see, each animation file can contain several types of items. But as each game uses its own unique version of animation engine, none of them will accept all types of items. If you want to build your own animations, make sure you don't use unsupported item types (check the supported types in the animations supplied with the games).

The playback frame rate seems to be around 6 frames per second (but I have not checked that for all files).

Detailed file structure

An animation file is composed of a sequence of items stored one after the other. All the items have the same general structure:

  • Header (6 bytes)
    • 2 bytes: Item type defined by two letters (see below for the list of item types)
    • 1 word (big endian): Size of data in bytes
    • 1 word (big endian): Item attribute
  • Data (size defined in header)

Meynaf has checked that the same set of item types is supported in Amiga versions of the games (DM 3.6, CSB 3.1, CSB 3.3, DM2 1.0): AN, BN, BR, DL, DO, EN, FO, MD, MF, MI, NE, PL, SD, SF, SO, TD, TR, WA.

Item types

Here is a list describing all the types of items found in animation files:

AN: ANimation

An AN item contains the definition of an animation. In Amiga versions, this item type is recognized but there is no associated action.
It is the first item in animation files, except in the following files where it is the second item, after a BR item:

  • CSB ENDA.DAT (Amiga 3.1 & 3.3 EN FR GE Game Disk, Amiga 3.1 EN Game Disk)
  • CSB ENDA.DAT (X68000 3.1 JP)
  • CSB ENDING.ANM (FM-Towns 3.1 EN JP)
  • CSB ENDING.ANM (PC-98 3.1 JP)

In the file DMII END (FM-Towns 1.0 JP, IBM PSV 1.0 JP, PC-9821 1.0 JP), the second item is another AN item identical to the first one.

  • Header (6 bytes)
    • 2 bytes: Item type: 'AN'
    • 1 word (big endian): Size of data in bytes: 0008h (8)
    • 1 word (big endian): Item attribute: 0000h
  • Data (8 bytes)
    • 1 word (big endian): Width of animation: 0140h (320)
    • 1 word (big endian): Height of animation: 00C8h (200)
    • 1 word (big endian): Bit depth: 0004h (4) (2^4 = 16 colors)
    • 1 word (big endian): Unknown use. Values found in files: 0001h, 0002h and 0003h.

    Here is the data found in the files:

    • 0140 00C8 0004 0001:
      • CSB TITL.DAT (Amiga 3.1 & 3.3 EN FR GE Game Disk, Amiga EN & FR & GE Utility Disk), TITLE.ANM (FM-Towns 3.1 EN JP)
    • 0140 00C8 0004 0002:
      • CSB ENDA.DAT (Amiga 3.1 & 3.3 EN FR GE Game Disk, Amiga 3.1 EN Game Disk)
      • CSB ENDING.ANM (FM-Towns 3.1 EN JP)
      • CSB STORY.ANM (FM-Towns 3.1 EN JP)
      • DMII ENDA.DAT (Sega CD 1.0 EN)
      • DMII STRY.DAT (Sega CD 1.0 EN)
      • DMII SWSH.DAT (Sega CD 1.0 EN)
    • 0000 0000 0004 0002:
      • DMII TITLE (IBM PSV 1.0 JP, PC-9801 1.0 JP)
      • DMII SWOOSH (FM-Towns 1.0 JP, IBM PSV 1.0 JP, PC-9801 1.0 JP, PC-9821 1.0 JP)
    • 0140 00C8 0004 0003:
      • All other files

BN: Branch Next

A BN item contains no data. It is a control item used in loops. See the Loops section for details.

  • Header (6 bytes)
    • 2 bytes: Item type: 'BN'
    • 1 word (big endian): Size of data in bytes: 0000h (0)
    • 1 word (big endian): Item attribute: 0000h

BR: BReak

A BR item contains no data. It is a control item used to define if the animation can be interrupted by the user with a mouse click or a key press. The actual action depends on the version, for example in Dungeon Master for PC you can only interrupt the animation by pressing a key and not by clicking the mouse.

  • Header (6 bytes)
    • 2 bytes: Item type: 'BR'
    • 1 word (big endian): Size of data in bytes: 0000h (0)
    • 1 word (big endian): Item attribute:
      • 0000h: The animation cannot be interrupted.
      • 0001h: The animation can be interrupted.

Animation files that do not contain any BR item can be interrupted by default.
Here are the files where the animation cannot be interrupted:

  • CSB ENDA.DAT (Amiga 3.1 & 3.3 EN FR GE Game Disk, Amiga 3.1 EN Game Disk)
  • CSB ENDA.DAT (X68000 3.1 JP)
  • CSB ENDING.ANM (FM-Towns 3.1 EN JP)
  • CSB ENDING.ANM (PC-98 3.1 JP)
  • DMII IPLY.DAT (Amiga 1.0 EN)
  • DMII SWSH.DAT (Amiga 1.0 EN)

In the following files, there are two BR items. The first one disables interruptions until the end of the animation. Then right before the end of the animation, a second BR item enables interruptions again, after the game credits are displayed:

  • DMII END (FM-Towns 1.0 JP, IBM PSV 1.0 JP, PC-9821 1.0 JP)
  • DMII ENDA.DAT (Amiga 1.0 EN)
  • DMII ENDA.DAT (Sega CD 1.0 JP)

CU: CUT

A CU item contains no data. It is a control item used to enable and disable the display in Dungeon Master II for Sega CD animations.

  • Header (6 bytes)
    • 2 bytes: Item type: 'CU'
    • 1 word (big endian): Size of data in bytes: 0000h (0)
    • 1 word (big endian): Item attribute:
      • 0000h: The display is enabled.
      • 0001h: The display is disabled (the screen is black).

In the original animation files, CU items are always used to surround two items FS and PL (the order of which may vary):
CU with attribute set to 1 (disable display)
FS then PL, or PL then FS (set up the image and palette while this cannot be seen by the user)
CU with attribute set to 0 (enable display)
Note: sometimes the first CU is omitted (in files from the Japanese version).

DL: Delta Layer

A DL item contains an image with only the differences (delta) from the previous frame. Specific transparency codes are used in the encoded image, meaning previous pixels are not changed.
In order to decode an image corresponding to a DL item, you need to decode first the previous EN item (full image) as well as all other DL items up to the DL item you want to decode.

  • Header (6 bytes)
    • 2 bytes: Item type: 'DL'
    • 1 word (big endian): Size of data in bytes: x
    • 1 word (big endian): Item attribute: Display duration (number of frames)
  • Data (x bytes)
    • 1 word: Signature: FF81h (65409)
    • 1 IMG1 encoded image.

DO: DOne

The last item of all the analyzed animation files is always a DO item which marks the end of the animation.
However, in Amiga versions, the code does not make this item mandatory.

  • Header (6 bytes)
    • 2 bytes: Item type: 'DO'
    • 1 word (big endian): Size of data in bytes: 0000h (0)
    • 1 word (big endian): Item attribute: 0000h

Note: In the following animations, the size of the DO item is set to 0008h (8), but the item really does not have any data:

  • DMII ENDA.DAT (Sega CD 1.0 EN)
  • DMII STRY.DAT (Sega CD 1.0 EN)
  • DMII SWSH.DAT (Sega CD 1.0 EN)

EN: ENcoded image

An EN item contains a full screen base image. The animation is then achieved by "patching" that image with DL items.
In Amiga versions, the image is copied directly to the frame buffer. The original program continues to read and decode the animation file while the image is displayed in order to save time. It also stores palette items (applied for EN and DL items) and music items but not sound items.

  • Header (6 bytes)
    • 2 bytes: Item type: 'EN'
    • 1 word (big endian): Size of data in bytes: x
    • 1 word (big endian): Item attribute: Display duration (number of frames)
  • Data (x bytes)
    • 1 IMG1 encoded image.

FO: FOr

A FO item contains no data. It is a control item used to repeat a sequence of animation items several times.
On the Amiga versions, the animation engine supports a maximum of 16 nested loops. See the Loops section for details.

  • Header (6 bytes)
    • 2 bytes: Item type: 'FO'
    • 1 word (big endian): Size of data in bytes: 0000h (0)
    • 1 word (big endian): Item attribute: Number of times to repeat sequence

FS: Full Screen

An FS item contains a full screen base image in Dungeon Master II for Sega CD animations.

  • Header (6 bytes)
    • 2 bytes: Item type: 'FS'
    • 1 word (big endian): Size of data in bytes: 7D04h (32004)
    • 1 word (big endian): Item attribute: Unknown value (unknown meaning)
  • Data (32004 bytes)
    • 4 bytes: 1 dword (big endian): Display time. This value indicates when to display the image in the timeline (this value is also present in GD items). As a consequence, the values are always increasing from first to last FS/GD item in an animation. For example, if an FS item is located between two GD items, the dword value of the FS item will be between the two values of the GD items. The timeline seems linked to the audio stream.
    • 32000 bytes: Raw 320x200 16 colors image. The most significant nibble of the first byte is the top left pixel of the image. Other pixels follow from left to right and then top to bottom.

Note: There is always a PL item before an FS item, except in DMII ENDA.DAT (Sega CD 1.0 JP), DMII SWSH.DAT (Sega CD 1.0 JP) and DMII TITL.DAT (Sega CD 1.0 EN & JP) where the PL item is stored after the FS item.

GD: Graphic Delta

A GD item contains an image with only the differences (delta) from the previous frame. It is used only in Dungeon Master II for Sega CD animations and is the functional equivalent of DL items on other platforms.
GD items contain uncompressed tile based graphics without transparency whereas DL items contain compressed full bitmaps with transparency.

  • Header (6 bytes)
    • 2 bytes: Item type: 'GD'
    • 1 word (big endian): Size of data in bytes: x
    • 1 word (big endian): Item attribute: Number of graphic tiles in the item = NbTiles
  • Data (4 + 38 x NbTiles bytes)
    • 1 dword (big endian): Display time. This value indicates when to display the image in the timeline (this value is also present in FS items). As a consequence, the values are always increasing from first to last FS/GD item in an animation. The timeline seems linked to the audio stream.
    • NbTiles x 34 bytes:
      • 1 word (big endian): Tile ID
      • 32 bytes: Tile data. Each tile is 8x8 = 64 pixels. Each nibble of data contains the color index of the pixel. The most significant nibble of the first byte is the top left pixel of the tile. Other pixels follow from left to right and then top to bottom.
    • NbTiles x 4 bytes:
      • 1 word (big endian): Tile display coordinates
        • Bits 15-12: Unused (always 0000)
        • Bits 11-7: Y coordinate of the tile. Multiply by 8 to obtain pixel coordinates.
        • Bits 6-1: X coordinate of the tile. Multiply by 8 to obtain pixel coordinates.
        • Bit 0: Unused (always 0)
      • 1 word (big endian): Tile ID. The ID of the tile to display. It always refer to a tile ID defined in the same GD item. What is the meaning of the values of Tile IDs? Can any value be used for any tile or are they like some sort of addresses?

MD: Music Data

An MD item contains a standard MIDI file.

  • Header (6 bytes)
    • 2 bytes: Item type: 'MD'
    • 1 word (big endian): Size of data in bytes: x
    • 1 word (big endian): Item attribute: 0000h
  • Data (x bytes)
    • In CSB ENDING.ANM (FM-Towns 3.1 EN JP) and CSB STORY.ANM (FM-Towns 3.1 EN JP), 2 bytes with values 01 38. The FM-Towns animation engine completely ignores MD items so they have not effect.
    • In all other files from X68000 and PC-98 versions, the data is a standard MIDI file.

MF: Music File

An MF item contains the name of an external file containing music data.

  • Header (6 bytes)
    • 2 bytes: Item type: 'MF'
    • 1 word (big endian): Size of data in bytes: x
    • 1 word (big endian): Item attribute: 0000h
  • Data (x bytes)
    • An ASCII string with one or two 00h bytes at the end so that the total number of bytes is even.

MI: Music Initialization

In all versions except Chaos Strikes Back for FM-Towns:
An MI item contains no data. It is a control item used to start playing a music. The item attribute contains the index of the music to play, as several musics can have been previously defined with MD or MF items.

  • Header (6 bytes)
    • 2 bytes: Item type: 'MI'
    • 1 word (big endian): Size of data in bytes: 0000h (0)
    • 1 word (big endian): Item attribute: Index of music to play (starting at 1).

In Chaos Strikes Back for FM-Towns: An MI item behaves likes a TR item and causes the music to stop with a fade-out.

NE: NExt

A NE item contains no data. It is a control item used in loops. See the Loops section for details.

  • Header (6 bytes)
    • 2 bytes: Item type: 'NE'
    • 1 word (big endian): Size of data in bytes: 0000h (0)
    • 1 word (big endian): Item attribute: 0000h

P8: Palette of preset colors

A P8 item contains a color palette. These palettes are used when a normal PL palette cannot be used. On PC when running in EGA mode the color palette is fixed. On PC-98 in 8-color mode, the 8 colors are also fixed. The PL item cannot be used to define custom colors and the P8 item is used to map the colors used in the animation to the preset colors in the default PC EGA / PC-98 8-color palette (the animations are not as nice as in PC VGA mode / PC-98 16-color mode where the game can choose its own colors).

  • Header (6 bytes)
    • 2 bytes: Item type: 'P8'
    • 1 word (big endian): Size of data in bytes: 0010h (16)
    • 1 word (big endian): Item attribute: 0000h
  • Data (16 bytes)
    • 1 byte per color used in the animation: The meaning of these bytes differ on PC and PC-98.
      On PC: For each of the 16 colors used in the animation, each byte contains the color number to use from the default EGA palette (valid values thus range from 0 to 15). The EGA default palette is made of the following colors:
      00 #000000 Black
      01 #0000AA Blue
      02 #00AA00 Green
      03 #00AAAA Cyan
      04 #AA0000 Red
      05 #AA00AA Magenta
      06 #AA5500 Brown
      07 #AAAAAA Light gray
      08 #555555 Dark gray
      09 #5555FF Bright blue
      10 #55FF55 Bright green
      11 #55FFFF Bright cyan
      12 #FF5555 Bright red
      13 #FF55FF Bright magenta
      14 #FFFF55 Bright yellow
      15 #FFFFFF White

      On PC-98: The screen resolution is 640x400 on PC-98. The animation resolution is 320x200, so each animation pixel is drawn using 4 pixels on screen:

      AB
      CD

      In 16-color mode, the colors are defined from a palette of 16x16x16=4096 possible colors (see PL item) and all 4 screen pixels are drawn using the same color.
      In 8-color mode, the 8 colors are predefined, and the 4 screen pixels may be drawn using several colors (this is called dithering and results in a better looking image).

      Red Green Blue Color name Color
      0 0 0 Black
      0 0 1 Blue
      0 1 0 Green
      0 1 1 Cyan
      1 0 0 Red
      1 0 1 Magenta
      1 1 0 Yellow
      1 1 1 White

      The 16 bytes define 16 color mappings between the 16 color indices used by each animation pixel and the colors of the 4 screen pixels.

      • Bit 0:
        • 0: Pixel D is black
        • 1: Pixel D uses the same color as pixel B
      • Bit 1: Red component of pixels A and C
      • Bit 2: Green component of pixels A and C
      • Bit 3: Blue component of pixels A and C
      • Bit 4: Red component of pixel B
      • Bit 5: Green component of pixel B
      • Bit 6: Blue component of pixel B
      • Bit 7: Ignored, always 0

PL: PaLette

A PL item contains a 16 colors palette.

  • Header (6 bytes)
    • 2 bytes: Item type: 'PL'
    • 1 word (big endian): Size of data in bytes: 0042h (66)
    • 1 word (big endian): Item attribute: 0000h
  • Data (66 bytes)
    • 1 word (big endian): Number of colors in palette: 0010h (16)

    Four bytes for each color (4 bytes * 16 colors = 64 bytes):

    • 1 byte: Color number (0-15)
    • 1 byte: Most significant nibble (ignored): 0h, Least significant nibble: Red value (0-15)
    • 1 byte: Most significant nibble (ignored): 0h, Least significant nibble: Green value (0-15)
    • 1 byte: Most significant nibble (ignored): 0h, Least significant nibble: Blue value (0-15)

Note: In the file IPLY.DAT from Dungeon Master II for Amiga, the first nibbles of RGB values are not equal to 0h but identical to the second nibbles. However these first nibbles are ignored by the engine, as if they were equal to 0.

SD: Sound Data

An SD item contains sound data. Different encodings are used depending on the platform and game.

  • Header (6 bytes)
    • 2 bytes: Item type: 'SD'
    • 1 word (big endian): Size of data in bytes: x
    • 1 word (big endian): Item attribute: 0000h (value is 0001h for the last 'SD' item of a Sega CD animation, marking the end of the sound stream.)
  • Data (x bytes)
    • An SND2 encoded item in CSB ENDA.DAT (Amiga 3.1 & 3.3 EN FR GE Game Disk, Amiga 3.1 EN Game Disk), DMII END (PC-9801 1.0 JP), DMII ENDA.DAT (Amiga 1.0 EN), DMII SWSH.DAT (Amiga 1.0 EN), DMII TITL.DAT (Amiga 1.0 EN) and DMII TITLE (FM-Towns 1.0 JP, PC-9821 1.0 JP)
    • An SND3 encoded item in CSB STORY.ANM (FM-Towns 3.1 EN JP), CSB STORY.ANM (PC-98 3.1 JP), CSB ENDING.ANM (FM-Towns 3.1 EN JP) and CSB ENDING.ANM (PC-98 3.1 JP)
    • An SND4 encoded item in CSB ANIM.DAT (X68000 3.1 JP) and CSB ENDA.DAT (X68000 3.1 JP).
    • In files from DMII Sega CD, all SD items form a single stream of raw sound data. The sound samples are 8 bits, mono, 22050 Hz.
      In each sound sample, the 7 less significant bits define the absolute sample value and the most significant bit is used as a sign bit (if set to 1, the sample has a positive value, otherwise it is negative).

SF: Sound File

An SF item contains the name of an external file containing sound data. The format of the file should be the same as the data stored in an SD item.

  • Header (6 bytes)
    • 2 bytes: Item type: 'SF'
    • 1 word (big endian): Size of data in bytes: x
    • 1 word (big endian): Item attribute: 0000h
  • Data (x bytes)
    • An ASCII string with one or two 00h bytes at the end so that the total number of bytes is even.

SO: SOund

An SO item is a control item used to start playing a sound. It contains 0 or 4 bytes of data depending on the game version. The item attribute contains the index of the sound to play, as several sounds can have been previously defined with SD, SF or TD items.

  • Header (6 bytes)
    • 2 bytes: Item type: 'SO'
    • 1 word (big endian): Size of data in bytes: 0004h (4) or 0000h (0)
    • 1 word (big endian): Item attribute: Index of sound to play (starting at 1)
  • Data (4 bytes)
    • 1 byte: Left volume. (Amiga: Add one and divide by 4)
    • 1 byte: Right volume. (Amiga: Add one and divide by 4)
    • 1 word: Playback frequency. Depending on the game and platform, this value specifies a frequency or a period. This value is sometimes ignored by the animation engine which uses a hardcoded sample rate (like in DM PC or DMII Amiga).
      In many files the value is 1388h. The frequency is 5000 Hz.
      In DMII ENDA.DAT (Amiga 1.0 EN) and DMII SWSH.DAT (Amiga 1.0 EN), the value is 157Ch. The frequency is 5500 Hz.
      In DMII TITL.DAT (Amiga 1.0 EN) and DMII TITLE (FM-Towns 1.0 JP, PC-9821 1.0 JP), the value is 03E8h. This value is incorrect.

Note: The size of SO items is 0 in the following files:

  • CSB ENDA.DAT (Amiga 3.1 & 3.3 EN FR GE Game Disk, Amiga 3.1 EN Game Disk). For this file, use 30h as the volume and 28Ah as the period.
    The exact sample rate is different on PAL (Europe) and NTSC (US) machines because the sound clock is based on the CPU clock which is different in PAL (7093790 Hz) and NTSC (7159090 Hz).
    The game does not define the frequency but the period for the sound chip. The sample rate is (CPUclock / (2 * period)). For example, with a period of 650 (028Ah, used in Amiga version 3.x animations), the sample rate would be:
    PAL: (7093790/2) / 650 = 5456 Hz
    NTSC: (7159090/2) / 650 = 5506 Hz
    Also note that in this file, the first sound defined with an SD item is never played.
  • CSB ENDING.ANM (FM-Towns 3.1 EN JP)
  • CSB STORY.ANM (FM-Towns 3.1 EN JP)

TD: Track Definition

A TD item contains no data. It is a control item used to refer to an external sound effect or music (not included in the animation file itself).
This item type is recognized in Amiga versions but is ignored.

  • Header (6 bytes)
    • 2 bytes: Item type: 'TD'
    • 1 word (big endian): Size of data in bytes: 0000h (0)
    • 1 word (big endian): Item attribute:
      • PC: Index of a sound item in the GRAPHICS.DAT file.
      • FM-Towns: Audio track number on the CD.
      • X68000 and PC-98: The value is 0000h. The animation engine on these platforms completely ignores MD items so they have not effect.

TR: Track Reset

In all versions except Chaos Strikes Back for FM-Towns:
A TR item contains no data. It is a control item used to stop music playback with a fade-out.
This item type is recognized in Amiga versions but is ignored.

  • Header (6 bytes)
    • 2 bytes: Item type: 'TR'
    • 1 word (big endian): Size of data in bytes: 0000h (0)
    • 1 word (big endian): Item attribute: 0001h (1)

In Chaos Strikes Back for FM-Towns: A TR item behaves likes an MI item. The item attribute specifies the track index to play (instead of a music index) as defined by TD items (who in turn refer to track numbers on the CD).

WA: WAit

A WA item contains no data. It is a control item used to pause the animation until an event occurs.
This item type is recognized in Amiga versions but is ignored.

  • Header (6 bytes)
    • 2 bytes: Item type: 'WA'
    • 1 word (big endian): Size of data in bytes: 0000h (0)
    • 1 word (big endian): Item attribute:
      • 0001h: (PC and FM-Towns only): Wait for end of sound
      • 0002h: (FM-Towns only): Wait for end of CD music
      • 0003h: (PC-98 and X68000 only): Wait for end of MIDI music. On X68000, there is an additional delay of 2 seconds after the end of music.

This item type is found in the following files: CSB ANIM.DAT (X68000 3.1 JP), CSB STORY.ANM (PC-98 3.1 JP) and CSB TITL.DAT (X68000 3.1 JP). The item attribute value is always 3 in these files.

XA: eXit Animation

An XA item is used to quickly display a final image when the animation is interrupted before the end. This item type is only suppored in Dungeon Master II for Sega CD animations. An XA item contains a sequence of other items (CU, PL, FS, CU) used to display an image. The items contained in the XA item are only played when the animation is interrupted.

  • Header (6 bytes)
    • 2 bytes: Item type: 'XA'
    • 1 word (big endian): Size of data in bytes: 7D5Eh (32094)
    • 1 word (big endian): Item attribute: 0000h
  • Data (32094 bytes)
    • 1 CU item (attribute value is 0001h) (6 bytes)
    • 1 PL item (6 + 66 bytes)
    • 1 FS item (6 + 32004 bytes)
    • 1 CU item (attribute value is 0000h) (6 bytes)

Note: In DMII ENDA.DAT (Sega CD 1.0 JP), DMII SWSH.DAT (Sega CD 1.0 JP) and DMII TITL.DAT (Sega CD 1.0 EN & JP), the PL item is stored after the FS item.

Loops

There are three item types that can be used to create loops in animations: FO, NE and BN.
A loop has the following structure (where XX, YY, ZZ and RR represent any valid instruction):

FO (n)
  XX
  YY
  ZZ
  ...
NE
  RR
BN

A loop has the following behavior:

  • XX, the first instruction after the FO, is only executed once during the first iteration. You may think of this instruction as an initialization.
  • YY, ZZ and all subsequent instructions until the NE are executed during each iteration. You may think of these instructions as the animation steps to repeat.
  • RR, the single instruction between the NE and the BN is executed during each iteration except the last one. You may think of this instruction as a cleanup instruction that will revert the screen back to its state before the looping animation.

Using these rules, running the sample loop above with n = 3 would execute the following sequence of instructions:
XX YY ZZ RR YY ZZ RR YY ZZ
and then execution would continue with the first instruction located after the BN.

Note: There is a bug in the animation engine in Dungeon Master for PC 3.4. If you specify a number of iterations greater than 10 in the FO item then the loop is only executed once.
At the end of the animation in DM END (PC 3.4 EN, PC 3.4 EN FR GE) the text 'The End' should glitter 50 times but it only does it once because of this bug.

Animation Files

The following table will tell you how many items of each type are used in each animation file:

File Name / MD5 AN BN BR CU DL DO EN FO FS GD MD MF MI NE P8 PL SD SF SO TD TR WA XA
DM END (PC 3.4 EN, PC 3.4 EN FR GE)
C6DF13A7D542A809B10AA8F620145525
1 2 1 862 1 4 2 2 3 6 43 7
DM TITL.DAT (Amiga 3.6 EN FR GE), TITLE (PC 3.4 EN, PC 3.4 EN FR GE)
05C2AB94CE4DFFE51B63985F7B0D1822
1 1 51 1 2 1 2
CSB ANIM.DAT (Amiga 3.3 EN FR DE, Amiga FR Utility Disk)
C2A6E36E842FF15C07FCDD076542B7B1
1 1 844 1 7 1 1 7 5 16
CSB ANIM.DAT (Amiga EN Utility Disk)
524D099FD80D266E3FE222AFA5267583
1 1 844 1 7 1 1 7 5 16
CSB ANIM.DAT (Amiga GE Utility Disk)
4A47040D6009C399E1C18A9DE7347615
1 1 844 1 7 1 1 7 5 16
CSB ANIM.DAT (X68000 3.1 JP)
6178F91435A9317FD3AF5868017F95AD
1 1 844 1 7 2 2 7 5 16 1 2 1
CSB STORY.ANM (FM-Towns 3.1 EN JP)
926D7839BE04F3C9836A1ED477767A78
1 1 844 1 7 1 2 7 5 16 2 2
CSB STORY.ANM (PC-98 3.1 JP)
E5CABB3B7DE71A914742E917435C0E0D
1 1 844 1 7 2 2 6 7 5 16 1 2 1
CSB ENDA.DAT (Amiga 3.1 & 3.3 EN FR GE Game Disk, Amiga 3.1 EN Game Disk)
9F2B73FF73AD0032810D79021C900CA9
1 1 1 285 1 2 1 1 3 2 3
CSB ENDA.DAT (X68000 3.1 JP)
2D8194CA2CE25DECCE6A756674C3CAD7
1 1 1 285 1 2 1 1 1 1 3 2 5
CSB ENDING.ANM (FM-Towns 3.1 EN JP)
EF65AC2A8DD7554E8B4974D3845C8545
1 1 1 285 1 2 1 1 1 1 3 2 3 2 2
CSB ENDING.ANM (PC-98 3.1 JP)
33D9E3A84247E428E1989448D5DC66D6
1 1 1 285 1 2 1 1 1 1 2 3 2 5
CSB TITL.ANM (PC-98 3.1 JP)
2A6654FD2FDE8AEE980A7A8C0F067A7B
1 31 1 1 1 1 1 1
CSB TITL.DAT (Amiga 3.1 & 3.3 EN FR GE Game Disk, Amiga EN & FR & GE Utility Disk), TITLE.ANM (FM-Towns 3.1 EN JP)
5B590EA3A6F5EED513B5678B01468EE4
1 31 1 1 1
CSB TITL.DAT (X68000 3.1 JP)
F4DA1B2C69A38325F036E8EBEE5699D6
1 1 31 1 1 1 1 1 1
DMII END (FM-Towns 1.0 JP, IBM PSV 1.0 JP, PC-9821 1.0 JP)
B4A6A38657AC3C1857872952A25964D4
2 2 2 382 1 3 2 2 5
DMII END (PC-9801 1.0 JP)
898ACF479051965341B9E6104452D249
1 1 375 1 3 3 1
DMII ENDA.DAT (Amiga 1.0 EN)
7F7FC31C4A1F41B8B2AFA81953823FF1
1 2 438 1 4 4 14 57
DMII ENDA.DAT (Sega CD 1.0 EN)
7D716E35415E74CF69ACDC8EAC2196ED
1 2 1 1 843 3 876 1
DMII ENDA.DAT (Sega CD 1.0 JP)
25F44A7FE29FFE271F2D937D6BB15211
1 2 7 1 4 439 5 431 1
DMII IPLY.DAT (Amiga 1.0 EN)
B1708891AB8C841B8046688E3F5C189F
1 1 1 1 1
DMII STRY.DAT (Sega CD 1.0 EN)
6098038C7681C08E88DAFA244AD50493
1 2 1 1 1535 27 2015 1
DMII SWOOSH (FM-Towns 1.0 JP, IBM PSV 1.0 JP, PC-9801 1.0 JP, PC-9821 1.0 JP)
ECEC4D7AC081B099056531043191B55A
1 18 1 1 1
DMII SWSH.DAT (Amiga 1.0 EN)
ABCA5430912A5C2D3D35DD8142740C72
1 1 18 1 1 1 1 1
DMII SWSH.DAT (Sega CD 1.0 EN)
544DA39473CDBA6F97C4714F3F617FD2
1 2 1 1 35 1 47 1
DMII SWSH.DAT (Sega CD 1.0 JP)
CFF85B539BFE4BEB589E75B9BDC02959
1 1 1 1 1 18 1 20 1
DMII TITL.DAT (Amiga 1.0 EN)
F023FD370AB1594EECA5B139A244B063
1 1 224 1 1 1 2 5
DMII TITL.DAT (Sega CD 1.0 EN & JP)
C1E80401C83100319C142CF11ED44630
1 1 1 1 1 224 1 212 1
DMII TITLE (FM-Towns 1.0 JP, PC-9821 1.0 JP)
D795BAB0B392B61534F64163FBBEDC38
1 1 224 1 1 1 1 5
DMII TITLE (IBM PSV 1.0 JP, PC-9801 1.0 JP)
1780CA2972DF5FEBA5E232B11B79B0E5
1 151 1 1 1

Special Thanks

I wish to thank Zyx, the developer of GraphReader. I found in his source code most of the algorithm needed to decode the IMG1 encoded images in animations (I just had to complete it to manage the transparency of delta images).
Thanks to meynaf too for his work in understanding animations in Amiga versions.

History of this document

Version 2.2 - May 8, 2020
Updated and completed information about P8 (for PC-98), MD, TD and WA items
Version 2.1 - November 13, 2011
Updated and completed information about TR and MI item types based on feeback from Greatstone
Version 2.0 - March 5 2009
Updated and completed information about most item types.
Added information supplied by Meynaf regarding loops.
Added a link to an Interplay MVE file format documentation
Version 1.2 - March 8, 2006
Updated table with additional files and MD5 hashes.
Version 1.1 - May 4, 2004
Some information added about reading on a PC the Quicktime videos of the Macintosh version of Dungeon Master II.
Version 1.0 - February 9, 2003
First release