WBZ (File Format)

From Custom Mario Kart
(Redirected from WBZ)
Jump to: navigation, search

WBZ is an alternative compression format for Yaz0 (used in SZS files). It is dedicated to the WU8 patching file format to allow small files without copyrighted material. The alternative compression should also help to avoid false positives of the copyright file scanners.

See »File format: U8 archives« for related file formats.

File Format

The file format is very simple:

Offset Type Description
0x00 u32 The magic of WBZ: "WBZa" = 0x57425a61

The lower case 'a' means: first version. If ever a new version is defined, the letter will be increased.

0x04 8 bytes Copy of the first 8 bytes of the decompressed data. This copy should help tools to find out the file format of the decompressed file without the need of decompressing it. An example is the command: wszst filetype of Wiimms SZS Tools.
0x0c u32 The size of the decompressed data in network byte order (big endian).
0x10 * BZIP2 compressed data.

BZIP2 compression factors

The BZIP2 compression algorithm supports the compression levels 1 to 9. In general, level 9 is the best choice, because it produces the smallest files and is only a bit slower than the other level. But because track data has many repeated sequences, sometime other compression levels, and especially level 1, will give a better compression ratio.

A good way is to compress the data with level 1 and 9 and to use the smallest one. Wiimms SZS Tools do this.

File Extensions

Wiimms SZS Tools support these default file extensions:

archive format compression format file extension
U8 .u8
U8 Yaz0 .szs
U8 WBZ .bz
WU8 .wu8
WU8 Yaz0 .wu8
WU8 WBZ .wbz
all other type dependent
all other Yaz0 .szs
all other WBZ .bz

Conversion in Windows

The newest version of Wiimms SZS Tools supports SZS from and to WBZ conversions via SendTo of Windows context menu. They also support WU8 as source.

  1. Install the current version of Wiimms SZS Tools.
  2. Install the SendTo extension with: install-sendto.bat.
  3. If not done, create the autoadd library:
    1. Extract the directory /Race/Course of the Mario Kart Wii DVD.
    2. Select the extracted directory with a right click and call SendTo | create-autoadd-library.
  4. Now you can convert each SZS and WBZ by using SendTo | convert-*.

You can also use the WBZ Converter.


The following tools can handle WBZ files: