VVC file format

Applies to:
BG2, BG2: ToB

General Description
This file format describes visual "spell casting" effects (BAM files) with optional sounds (WAVC files). VVCs can be invoked by some script actions (e.g. CreateVisualEffect, CreateVisualEffectObject) and by some effects (e.g. "Play 3D effect").

VVC Files use a 3D co-ordinates system when playing the exact location of VVC animations. Infinity Engine Games are rendered from an isometric angle; this means that the X-Y-Z axis need to be percieved within this isometric frame to properly understand how VVC files will play. The screenshot below demonstrates each axis, accordingly:
X is up or down.
Y is the distance between the feet of the character and the animation
Z is the distance between the head of the character and the animation


Detailed Description

These files have constant length 1ECh bytes.
Offset Size (data type) Description
0x0000 4 (char array) Signature ('VVC ')
0x0004 4 (char array) Version ('V1.0')
0x0008 8 (resref) Animation resref (BAM)
0x0010 8 (resref) Animation resref (BAM) - unused
0x0018 2 (word) Display flags
  • bit 0: Transparent
  • bit 1: Translucent
  • bit 2: Translucent shadow
  • bit 3: Blended
  • bit 4: Mirror X axis
  • bit 5: Mirror Y axis
  • bit 6: Clipped
  • bit 7: Copy from back
  • bit 8: Clear fill
  • bit 9: 3d blend
  • bit 10: Not covered by wall
  • bit 11: Persist through timestop
  • bit 12: Ignore dream palette
  • bit 13: 2d blend
  • bit 14: Unused
  • bit 15: Unused
0x001a 2 (word) Colour flags
  • bit 0: Not light source
  • bit 1: Light source
  • bit 2: Internal brightness
  • bit 3: Timestopped
  • bit 4: Unused
  • bit 5: Internal gamma
  • bit 6: Non-reserved palette
  • bit 7: Full palette
  • bit 8: Unused
  • bit 9: Sepia
  • bit 10: Unused
  • bit 11: Unused
  • bit 12: Unused
  • bit 13: Unused
  • bit 14: Unused
  • bit 15: Unused
0x001c 4 (dword) Unused
0x0020 4 (dword) Sequence flags
  • bit 0: Looping
  • bit 1: Special lighting
  • bit 2: Modify for height
  • bit 3: Draw animation
  • bit 4: Custom palette
  • bit 5: Purgeable
  • bit 6: Not covered by wallgroups
  • bit 7: Mid-level brighten
  • bit 8: High-level brighten
0x0024 4 (dword) Unused
0x0028 4 (dword) X position (0 is smallest)
0x002c 4 (dword) Y position - distance between feet and animation (0 is the highest and FF is lowest)
0x0030 4 (dword) Use orientation
0x0034 4 (dword) Frame rate (1 = slow)
0x0038 4 (dword) Number of orientations (0/1/8/16)
0x003c 4 (dword) Base orientation
0x0040 4 (dword) Position flags
  • bit 0: Orbit target
  • bit 1: Relative to target
  • bit 2: Unused
  • bit 3: Ignore orientation
0x0044 8 (resref) Bitmap palette
0x004c 4 (dword) Z offset position
0x0050 4 (dword) Lighting effect radius/Centre X position
0x0054 4 (dword) Centre Y position
0x0058 4 (dword) Lighting effect brightness
0x005c 4 (dword) Duration (frames)
0x0060 8 (resref) Name (for internal use)
0x0068 4 (dword) First BAM sequence (introduction)
0x006c 4 (dword) Second BAM sequence (duration)
0x0070 4 (dword) Current animation sequence
0x0074 4 (dword) Continuous sequences boolean
0x0078 8 (resref) First WAVC sound (introduction)
0x0080 8 (resref) Second WAVC sound (duration)
0x0088 8 (resref) Alpha blending animation
0x0090 4 (dword) Third BAM sequence (ending)
0x0094 8 (resref) Third WAVC soud (ending)
0x009c 336 (bytes) Unused