BOL (File Format)

This page describes the .bol format, as found in course.arc files .bol is used for course data.

File Format
Literally copied from Tockdom

File Header
The file header is a 0x7C byte structure, as follows:

Sections
The file consists of a series of sections, each describing a different aspect of the course setup.

Section 1: Enemy/Item points
Section 1 describes enemy/item points; the routes of CPU racers and items such as red shells. The CPU racers and items attempt to follow the path described by each group of points. Each entry is a 0x20 byte structure as follows:

NOTE: Even when drifting is configured, it's still up to the AI kart to start drifting or not, depending on current speed, entry angle, etc. On the other hand, swerving is fully dictated by the setting: AI karts will swerve if configured.

Section 2: Checkpoints
The first part of Section 2 describes checkpoint grouping; how the routes of checkpoints link together. Each entry is a 0x14 byte structure as follows:

The second part of Section 2 describes checkpoints; the routes players must follow to count laps. The racers must follow the path described by each group of points (as determined by the first part of Section 2). Each entry is a 0x1C byte structure as follows:

The byte at 0x18 allows for developer-intended shortcuts. Checkpoints that share a non-zero value at this offset will be thought of as optional for lap progression, that is, the lap progression will halt upon entering the checkpoint boxes associated with these checkpoints and jump to where it should be when the checkpoint box region is exited. In vanilla, only consecutive checkpoint share non-zero values, but if applied to nonconsecutive checkpoints, all checkpoints between the two will be counted in the same group.

Section 3: Paths
Section 3 describes paths; these are paths for many things including cameras and objects. Each entry is a 0x10 byte structure as follows:

Section 4: Path Points
Section 4 describes path points. Each entry is a 0x20 byte structure as follows:

Section 5: Objects
Section 5 describes objects. Each entry is a 0x40 byte structure as follows:

The usage of the values at offsets 0x30 - 0x3E differ from object to object - a full documentation can be found in the Objects page.

Section 6: Kart Start Points
Section 6 describes kart points; the starting positions of racers. Each entry is a 0x28 byte structure as follows:

Section 7: Areas
Section 7 describes areas; used to determine for example which camera to use. Each entry is a 0x38 byte structure as follows:

Section 8: Cameras
Section 8 describes Cameras. Each entry is a 0x48 byte structure as follows:

Note: Replay cameras can be used as opening cameras.

Section 9: Respawn Points
Section 9 describes Jugem points; the respawn positions. Each entry is a 0x20 byte structure as follows:

Section 10: Lights
Unknown, but referenced as LightParam.

Section 11
This section is referenced as "MG" which can possibly stand for MiniGame. The section is always 0x40 bytes long, with each entry being 0x08 bytes long. After further reverse engineering, it has been found that this section is unused in the game. There's a game mode that is referenced as Rabbit, that has a check named isRidingBossPakkun, which means that this may have been Renegade Roundup, which appears in Mario Kart 8 Deluxe.

Rotation Vector
The Mario Kart: Double Dash!! rotation vector consists of 3 Int32 values. The first two values form a two-dimensional direction vector with the first pointing in X-direction and the second pointing in Z-direction. The third value represents the length of the vector (it is quite inaccurate, though). Its value is usually 0x27100000 (655360000 in base 10). Using trigonometry, the rotation angle around the Y-axis can be calculated as follows:

angle (in degree) = sign(value1 + 0.5) * arccos(value2 / value3) * (180 / pi)

This C# snippet can properly determine the value as well:

public static double returnRotations(int xrot, int yrot, int zrot) { double radToDeg = 57.2957795d; double angle1 = radToDeg * Math.Atan2((double)yrot / (double)zrot, (double)xrot / (double)zrot); angle1 = 90 - angle1; return angle1; }

Tools

 * DouBol Dash by shibboleet
 * Mkdd-track-editor by Yoshi2