101 lines
No EOL
2.6 KiB
Text
101 lines
No EOL
2.6 KiB
Text
//------------------------------------------------
|
|
//--- 010 Editor v11.0.1 Binary Template
|
|
//
|
|
// File: vt2_nav_data.bt
|
|
// Authors: Lucas Schwiderski
|
|
// Version:
|
|
// Purpose:
|
|
// Category: Vermintide 2
|
|
// File Mask: *.(NavData|nav_data)
|
|
// ID Bytes: 42 6C 6F 62 41 67 67 46 69 6C 65 00
|
|
// History:
|
|
//------------------------------------------------
|
|
|
|
string file_type;
|
|
uint32 unknown_1;
|
|
if (unknown_1 != 0)
|
|
return "Unexpected value";
|
|
|
|
|
|
// Equals `02` for empty.level, `03` for all others so far
|
|
// The empty level was missing a section, so that's likely the count for it
|
|
uint32 count_sections;
|
|
|
|
// TODO: Create an enum for section types and make this section stuff proper
|
|
struct {
|
|
uint32 section_1_type;
|
|
if (section_1_type != 0x0500)
|
|
return "Unexpected value";
|
|
|
|
uint32 unknown_4;
|
|
if (unknown_4 != 0)
|
|
return "Unexpected value";
|
|
|
|
|
|
// Both always `0x28`
|
|
uint32 unknown_5;
|
|
uint32 unknown_6;
|
|
|
|
uint32 build_string_length;
|
|
|
|
// Always `0x04`
|
|
uint32 unknown_8;
|
|
|
|
char build_string[build_string_length];
|
|
|
|
// Padding to get `build_string_length` to divide by 4 (technically `sizeof(uint32)`)
|
|
if (build_string_length % 4 != 0) {
|
|
byte build_string_padding[4 - (build_string_length % 4)];
|
|
}
|
|
} Header;
|
|
|
|
uint32 section_2_type;
|
|
if (section_2_type == 0x01) {
|
|
|
|
uint32 count_nav_meshes;
|
|
|
|
struct NavMesh {
|
|
uint32 data_length;
|
|
// Could be length of the following section
|
|
uint32 section_length;
|
|
|
|
byte data[data_length];
|
|
} nav_meshes[count_nav_meshes] <optimize=false>;
|
|
|
|
uint32 section_3_type;
|
|
}
|
|
|
|
uint32 unknown_12;
|
|
// For any non-empty navdata, this seems to increas by 4
|
|
uint32 unknown_13;
|
|
// Seems to be always the same as `unknown_13`
|
|
uint32 unknown_14;
|
|
uint32 unknown_15;
|
|
uint32 unknown_16;
|
|
uint32 unknown_17;
|
|
uint32 unknown_18;
|
|
uint32 unknown_19;
|
|
uint32 unknown_20;
|
|
uint32 unknown_21;
|
|
uint32 unknown_22;
|
|
|
|
// Not actually null-terminated
|
|
char header_sector_descriptor[16];
|
|
|
|
struct SectorDescriptor{
|
|
uint32 unknown_1;
|
|
uint32 sector_name_header_length;
|
|
uint32 unknown_3;
|
|
uint32 sector_name_value_length;
|
|
uint32 generator_type_name_length;
|
|
uint32 unknown_6;
|
|
uint32 unknown_7;
|
|
uint32 unknown_8;
|
|
uint32 unknown_9;
|
|
} sector_descriptor;
|
|
|
|
// Terminated by two! nulls
|
|
char header_sector_name[sector_descriptor.sector_name_header_length];
|
|
// Padding to get string length to divide by 4 (technically `sizeof(uint32)`)
|
|
byte header_sector_name_padding[4 - (sector_descriptor.sector_name_header_length % 4)];
|
|
string sector_name; |