Enemy path shortest table.bin (File Format)

From Wexos's Wiki
Revision as of 17:29, 1 May 2024 by Wexos (talk | contribs) (Imported from avsys wiki)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigationJump to search

enemy_path_shortest_table.bin is a file found in battle arenas in Mario Kart 8 Deluxe. It specifies distances between all enemy path points in a battle BYAML file. It seems to be used for finding in what direction the shortest path exists, when an enemy CPU is supposed to drive towards a specific area.

File Format

The file byte order is always little endian.

Header

The file starts with the following header:

Offset Type Description
0x00 Char[4] File magic. Always STBL in ASCII.
0x04 UInt16 Total number of enemy points (N) in battle muunt BYAML.
0x06 UInt16 Header size. Always 8.

Entry

A file contains N * N entries. Each entry specifies the relationship between two points. They have the following structure:

Offset Type Description
0x00 Float Distance between the two points.
0x04 UInt16 Path ID, which specifies the next point of the shortest path. This presumably is used to find the whole path the CPU should take to go to a specific area.
0x06 UInt16 Point ID, which specifies the next point of the shortest path.

Tools

The following tools can handle enemy_path_shortest_table.bin files:

  • (none)