From efbb37e3936b7b45ebe4fb3eb48c749d1a7d96f5 Mon Sep 17 00:00:00 2001 From: Michael Fabian 'Xaymar' Dirks Date: Thu, 29 Feb 2024 00:28:28 +0100 Subject: [PATCH] Update 010 templates --- .../{helldivers2_common.bt => common.bt} | 2 +- extra/010 Editor/helldivers2_datatype.bt | 85 ----- extra/010 Editor/helldivers2_mesh.bt | 85 ----- extra/010 Editor/helldivers2_raw.bt | 95 ----- .../{helldivers2_meshinfo.bt => unit.bt} | 332 ++++++++++-------- 5 files changed, 185 insertions(+), 414 deletions(-) rename extra/010 Editor/{helldivers2_common.bt => common.bt} (99%) delete mode 100644 extra/010 Editor/helldivers2_datatype.bt delete mode 100644 extra/010 Editor/helldivers2_mesh.bt delete mode 100644 extra/010 Editor/helldivers2_raw.bt rename extra/010 Editor/{helldivers2_meshinfo.bt => unit.bt} (57%) diff --git a/extra/010 Editor/helldivers2_common.bt b/extra/010 Editor/common.bt similarity index 99% rename from extra/010 Editor/helldivers2_common.bt rename to extra/010 Editor/common.bt index ade336c..9cd03c4 100644 --- a/extra/010 Editor/helldivers2_common.bt +++ b/extra/010 Editor/common.bt @@ -110,4 +110,4 @@ struct f64mat4x2_t { f64vec4_t _; f64vec4_t _; }; struct f64mat4x3_t { f64vec4_t _; f64vec4_t _; f64vec4_t _; }; struct f64mat4x4_t { f64vec4_t _; f64vec4_t _; f64vec4_t _; f64vec4_t _; }; -#endif \ No newline at end of file +#endif diff --git a/extra/010 Editor/helldivers2_datatype.bt b/extra/010 Editor/helldivers2_datatype.bt deleted file mode 100644 index 5752e56..0000000 --- a/extra/010 Editor/helldivers2_datatype.bt +++ /dev/null @@ -1,85 +0,0 @@ -// Copyright 2024 Michael Fabian 'Xaymar' Dirks -// -// Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: -// -// 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. -// 2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. -// 3. Neither the name of the copyright holder nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission. -// -// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS “AS IS” AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -// - -#ifndef HELLDIVERS2_DATATYPE -#define HELLDIVERS2_DATATYPE - -#ifndef IS_INCLUDE - #define IS_INCLUDE - #define HELLDIVERS2_DATATYPE_INCLUDE -#endif -#include "helldivers2_common.bt" -#ifdef HELLDIVERS2_DATATYPE_INCLUDE - #undef IS_INCLUDE -#endif - -enum datatype_element_type { - POSITION = 0, - __COLOR = 1, - TEXCOORD = 4, - - BONE_WEIGHT = 6, - BONE_INDEX = 7, -}; - -enum datatype_element_format { - F32VEC3 = 2, - - //XBGR = 25, or RGBA = 25, or ARGB = 25, - ABGR = 26, - - F16VEC2 = 29, - F16VEC4 = 31, -}; - -struct datatype_t { - BigEndian(); - uint32_t magic_number ; - LittleEndian(); - uint32_t __unk00 ; - struct element_t { - datatype_element_type type ; - datatype_element_format format ; - uint32_t layer ; - uint32_t __unk00 ; - uint32_t __unk01 ; - } elements[16]; - uint32_t num_elements ; - uint32_t __unk01 ; - struct { - BigEndian(); - uint32_t magic_number ; - LittleEndian(); - uint32_t __unk00[3] ; - uint32_t vertex_count ; - uint32_t vertex_stride ; - uint32_t __unk01[4] ; - } __unk02; - struct { - BigEndian(); - uint32_t magic_number ; - LittleEndian(); - uint32_t __unk09[3] ; - uint32_t index_count ; - uint32_t __unk10[5] ; - uint32_t vertex_offset ; - uint32_t vertex_size ; - uint32_t index_offset ; - uint32_t index_size ; - uint32_t __unk11[4] ; - } __unk03; -}; - -#ifndef IS_INCLUDE -datatype_t DataType; -#endif - -#endif diff --git a/extra/010 Editor/helldivers2_mesh.bt b/extra/010 Editor/helldivers2_mesh.bt deleted file mode 100644 index 85a9b4a..0000000 --- a/extra/010 Editor/helldivers2_mesh.bt +++ /dev/null @@ -1,85 +0,0 @@ -// Copyright 2024 Michael Fabian 'Xaymar' Dirks -// -// Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: -// -// 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. -// 2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. -// 3. Neither the name of the copyright holder nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission. -// -// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS “AS IS” AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -// - -#ifndef HELLDIVERS2_MESH -#define HELLDIVERS2_MESH - -#ifndef IS_INCLUDE - #define IS_INCLUDE - #define HELLDIVERS2_MESH_INCLUDE -#endif -#include "helldivers2_common.bt" -#ifdef HELLDIVERS2_MESH_INCLUDE - #undef IS_INCLUDE -#endif - -struct mesh_group_t { - uint32_t __unk00 ; - uint32_t vertex_offset ; - uint32_t vertex_count ; - uint32_t index_offset ; - uint32_t index_count ; - uint32_t __unk01 ; -}; - -struct mesh_t { - uint32_t __unk ; - uint32_t __unk ; - uint32_t __unk ; - uint32_t __unk ; - uint32_t __unk ; - uint32_t __unk ; - uint32_t __unk ; - uint32_t __unk ; - uint32_t __unk ; - uint32_t __unk ; - BigEndian(); - uint32_t __unk_commonhash ; - LittleEndian(); - uint32_t __varies ; - uint32_t __varies ; - uint32_t __unk ; - uint32_t __varies ; - uint32_t datatype ; - uint32_t __unk ; - uint32_t __unk ; - uint32_t __unk ; - uint32_t __unk ; - uint32_t __unk ; - uint32_t __unk ; - uint32_t __unk ; - uint32_t __unk ; - uint32_t __unk ; - uint32_t __unk ; - uint32_t materials ; - uint32_t material_offset ; - uint32_t __unk ; - uint32_t __unk ; - uint32_t groups ; - uint32_t group_offset ; - - FSeek(startof(this) + material_offset); - BigEndian(); - uint32_t material[materials] ; - LittleEndian(); - - FSeek(startof(this) + group_offset); - local uint32 i; - for (i = 0; i < groups; i++) { - mesh_group_t group; - } -}; - -#ifndef IS_INCLUDE -mesh_t Mesh; -#endif - -#endif diff --git a/extra/010 Editor/helldivers2_raw.bt b/extra/010 Editor/helldivers2_raw.bt deleted file mode 100644 index 054273d..0000000 --- a/extra/010 Editor/helldivers2_raw.bt +++ /dev/null @@ -1,95 +0,0 @@ -// Copyright 2024 Michael Fabian 'Xaymar' Dirks -// -// Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: -// -// 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. -// 2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. -// 3. Neither the name of the copyright holder nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission. -// -// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS “AS IS” AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -// - -OutputPaneClear();LittleEndian(); - -#define IS_INCLUDE -#include "helldivers2_common.bt" -#include "helldivers2_datatype.bt" -#include "helldivers2_mesh.bt" - -struct offset { - uint64_t datatype; - uint64_t mesh; - uint64_t vertices; - uint64_t indices; -} Offsets; - -FSeek(Offsets.datatype); -datatype_t DataType; - -FSeek(Offsets.mesh); -mesh_t Mesh; - -FSeek(Offsets.vertices); -struct vertex { - local uint32_t i; - for (i = 0; i < DataType.num_elements; i++) { - switch(DataType.elements[i].type) { - case POSITION: switch(DataType.elements[i].format) { - case F32VEC3: f32vec3_t position; break; - default: byte unknownFixMe[0x7FFFFFFF]; - }; break; - case __COLOR: switch(DataType.elements[i].format) { - case ABGR: u8vec4_t color; break; - default: byte unknownFixMe[0x7FFFFFFF]; - }; break; - case TEXCOORD: switch(DataType.elements[i].format) { - case F16VEC2: f16vec2_t texcoord; break; - default: byte unknownFixMe[0x7FFFFFFF]; - }; break; - default: - struct { - switch(DataType.elements[i].format) { - case 0: f32vec1_t _; break; - case 1: f32vec2_t _; break; - case 3: f32vec4_t _; break; - case 4: byte _[4]; break; - case 17: s32vec1_t _; break; - case 18: s32vec2_t _; break; - case 19: s32vec3_t _; break; - case 20: s32vec4_t _; break; - case 21: s8vec1_t _; break; - case 22: s8vec2_t _; break; - case 23: s8vec3_t _; break; - case 24: s8vec4_t _; break; - case 25: u8vec4_t _; break; - case 28: f16vec1_t _; break; - case 30: f16vec3_t _; break; - - case F32VEC3: f32vec3_t _; break; - - case ABGR: s8vec4_t _; break; - - case F16VEC2: f16vec2_t _; break; - case F16VEC4: f16vec4_t _; break; - - default: byte unknownFixMe[0x7FFFFFFF]; - }; - } el ; - break; - } - } -} Vertices[Mesh.DataInfo.vertex_count] ; - -FSeek(Offsets.indices); -struct face { - local uint32_t stride = DataType.__unk03.index_size / DataType.__unk03.index_count; - if (stride == 1) { - uint8_t idx[3]; - } else if (stride == 2) { - uint16_t idx[3]; - } else if (stride == 4) { - uint32_t idx[3]; - } else if (stride == 8) { - uint64_t idx[3]; - } -} Faces[Mesh.DataInfo.index_count / 3] ; \ No newline at end of file diff --git a/extra/010 Editor/helldivers2_meshinfo.bt b/extra/010 Editor/unit.bt similarity index 57% rename from extra/010 Editor/helldivers2_meshinfo.bt rename to extra/010 Editor/unit.bt index cfa913f..97fcb62 100644 --- a/extra/010 Editor/helldivers2_meshinfo.bt +++ b/extra/010 Editor/unit.bt @@ -15,62 +15,178 @@ // - GameBreaker (https://reshax.com/profile/731-gamebreaker/) for the helpful Stingray playlist video link. // - DKDave (https://reshax.com/profile/70-dkdave/) for pointing me at a file that revealed so much more about the mesh structure than we had known until now. - -#ifndef HELLDIVERS2_MESHINFO -#define HELLDIVERS2_MESHINFO +#ifndef HELLDIVERS2_UNIT +#define HELLDIVERS2_UNIT #ifndef IS_INCLUDE #define IS_INCLUDE - #define HELLDIVERS2_MESHINFO_INCLUDE + #define HELLDIVERS2_UNIT_INCLUDE #endif -#include "helldivers2_common.bt" -#include "helldivers2_datatype.bt" -#include "helldivers2_mesh.bt" -#ifdef HELLDIVERS2_MESHINFO_INCLUDE +#include "common.bt" +#ifdef HELLDIVERS2_UNIT_INCLUDE #undef IS_INCLUDE #endif -struct meshinfo_t { - uint32_t __unk ; - uint32_t __unk ; - BigEndian(); - uint64_t skeleton_bones_file_hash ; - LittleEndian(); +struct mesh_t { + struct mesh_header_t { + uint32_t __unk ; + uint32_t __unk ; + uint32_t __unk ; + uint32_t __unk ; + uint32_t __unk ; + uint32_t __unk ; + uint32_t __unk ; + uint32_t __unk ; + uint32_t __unk ; + uint32_t __unk ; + BigEndian(); + uint32_t __unk_commonhash ; + LittleEndian(); + uint32_t __varies ; + uint32_t __varies ; + uint32_t __unk ; + uint32_t __varies ; + uint32_t datatype ; + uint32_t __unk ; + uint32_t __unk ; + uint32_t __unk ; + uint32_t __unk ; + uint32_t __unk ; + uint32_t __unk ; + uint32_t __unk ; + uint32_t __unk ; + uint32_t __unk ; + uint32_t __unk ; + uint32_t materials ; + uint32_t material_offset ; + uint32_t __unk ; + uint32_t __unk ; + uint32_t groups ; + uint32_t group_offset ; + } header; + + FSeek(startof(this) + header.material_offset); + BigEndian(); + uint32_t material[header.materials] ; + LittleEndian(); - uint32_t __unk ; - uint32_t __unk ; - uint32_t __unk ; - uint32_t __unk ; + FSeek(startof(this) + header.group_offset); + local uint32 i; + for (i = 0; i < header.groups; i++) { + struct mesh_group_t { + uint32_t __unk00 ; + uint32_t vertex_offset ; + uint32_t vertex_count ; + uint32_t index_offset ; + uint32_t index_count ; + uint32_t __unk01 ; + } group; + } +}; + +enum datatype_element_type { + POSITION = 0, + __COLOR = 1, + TEXCOORD = 4, - uint32_t __unk ; - uint32_t __unk ; - uint32_t __unk ; - uint32_t __unk ; + BONE_WEIGHT = 6, + BONE_INDEX = 7, +}; + +enum datatype_element_format { + F32VEC3 = 2, - uint32_t __unkoffset ; - uint32_t __unkoffset ; - uint32_t __unkoffset ; - uint32_t __unkoffset ; + //XBGR = 25, or RGBA = 25, or ARGB = 25, + ABGR = 26, - uint32_t __unk ; - uint32_t __unk ; - uint32_t __unk ; - uint32_t __unkoffset ; + F16VEC2 = 29, + F16VEC4 = 31, +}; + +struct datatype_t { + BigEndian(); + uint32_t magic_number ; + LittleEndian(); - uint32_t __unkoffset ; - uint32_t __unk ; - uint32_t __unkoffset ; - uint32_t datatype_list_offset ; + uint32_t __unk00 ; + struct element_t { + datatype_element_type type ; + datatype_element_format format ; + uint32_t layer ; + uint32_t __unk00 ; + uint32_t __unk01 ; + } elements[16]; + uint32_t num_elements ; + uint32_t __unk01 ; - uint32_t __unkoffset ; - uint32_t mesh_list_offset ; - uint32_t __unk ; - uint32_t __unk ; + struct { + BigEndian(); + uint32_t magic_number ; + LittleEndian(); + uint32_t __unk00[3] ; + uint32_t vertex_count ; + uint32_t vertex_stride ; + uint32_t __unk01[4] ; + } __unk02; - uint32_t material_hashmap_offset ; + struct { + BigEndian(); + uint32_t magic_number ; + LittleEndian(); + uint32_t __unk09[3] ; + uint32_t index_count ; + uint32_t __unk10[5] ; + uint32_t vertex_offset ; + uint32_t vertex_size ; + uint32_t index_offset ; + uint32_t index_size ; + uint32_t __unk11[4] ; + } __unk03; +}; + +struct unit_t { + struct unit_header_t { + uint32_t __unk ; + uint32_t __unk ; + BigEndian(); + uint64_t skeleton_bones_file_hash ; + LittleEndian(); + + uint32_t __unk ; + uint32_t __unk ; + uint32_t __unk ; + uint32_t __unk ; + + uint32_t __unk ; + uint32_t __unk ; + uint32_t __unk ; + uint32_t __unk ; + + uint32_t __unkoffset ; + uint32_t __unkoffset ; + uint32_t __unkoffset ; + uint32_t __unkoffset ; + + uint32_t __unk ; + uint32_t __unk ; + uint32_t __unk ; + uint32_t __unkoffset ; + + uint32_t __unkoffset ; + uint32_t __unk ; + uint32_t __unkoffset ; + uint32_t datatype_list_offset ; + + uint32_t __unkoffset ; + uint32_t mesh_list_offset ; + uint32_t __unk ; + uint32_t __unk ; + + uint32_t material_hashmap_offset ; + } header; - if (__unkoffset[3] != 0) { - FSeek(__unkoffset[3]); + if (header.__unkoffset[3] != 0) { + FSeek(header.__unkoffset[3]); struct { uint32_t count ; uint32_t __unk ; @@ -79,8 +195,8 @@ struct meshinfo_t { } __unk3; } - if (__unkoffset[2] != 0) { - FSeek(__unkoffset[2]); + if (header.__unkoffset[2] != 0) { + FSeek(header.__unkoffset[2]); struct { uint32_t count ; uint32_t __unk ; @@ -125,8 +241,8 @@ struct meshinfo_t { } __unk2; } - if (__unkoffset[0] != 0) { - FSeek(__unkoffset[0]); + if (header.__unkoffset[0] != 0) { + FSeek(header.__unkoffset[0]); struct { uint32_t count ; uint32_t offsets[count] ; @@ -170,8 +286,8 @@ struct meshinfo_t { } __unk0; } - if (__unkoffset[1] != 0) { // - FSeek(__unkoffset[1]); + if (header.__unkoffset[1] != 0) { // + FSeek(header.__unkoffset[1]); struct { uint32_t count ; uint32_t __unk ; @@ -190,8 +306,8 @@ struct meshinfo_t { } __unk1; } - if (__unkoffset[6] != 0) { // 768 bytes. Suspicious. - FSeek(__unkoffset[6]); + if (header.__unkoffset[6] != 0) { // 768 bytes. Suspicious. + FSeek(header.__unkoffset[6]); struct { uint32_t count ; uint32_t offsets[count] ; @@ -221,8 +337,8 @@ struct meshinfo_t { } __unk6; } - if (datatype_list_offset != 0) { - FSeek(datatype_list_offset); + if (header.datatype_list_offset != 0) { + FSeek(header.datatype_list_offset); struct { uint32 count ; uint32 offsets[count] ; @@ -239,8 +355,8 @@ struct meshinfo_t { } datatypes; } - if(mesh_list_offset > 0) { - FSeek(mesh_list_offset); + if(header.mesh_list_offset > 0) { + FSeek(header.mesh_list_offset); struct { uint32 count ; uint32 offsets[count]; @@ -256,8 +372,8 @@ struct meshinfo_t { } meshes; } - if(material_hashmap_offset > 0) { - FSeek(material_hashmap_offset); + if(header.material_hashmap_offset > 0) { + FSeek(header.material_hashmap_offset); struct { uint32 count ; BigEndian(); @@ -267,118 +383,38 @@ struct meshinfo_t { } materials; } - if (__unkoffset[7] != 0) { - FSeek(__unkoffset[7]); + if (header.__unkoffset[7] != 0) { + FSeek(header.__unkoffset[7]); struct { + uint32_t count ; uint32_t __unk ; - uint32_t __unk ; + // If everything is a single file, then __unk7 is the start of mesh data. + // However the evidence suggests the opposite: + // - All offsets are relative to the start of the gpu_resources file, not relative to the start of the unit file. + // - There is no pointer or value that corrects for this error anywhere. + // - It doesn't make sense to treat it as one file. } __unk7; } // Never seen these? - if (__unkoffset[4] != 0) { - FSeek(__unkoffset[4]); + if (header.__unkoffset[4] != 0) { + FSeek(header.__unkoffset[4]); struct { uint32_t __unk ; } __unk4; } - if (__unkoffset[5] != 0) { - FSeek(__unkoffset[5]); + if (header.__unkoffset[5] != 0) { + FSeek(header.__unkoffset[5]); struct { uint32_t __unk ; } __unk5; } - // BMS error causes this to repeat. }; #ifndef IS_INCLUDE -meshinfo_t MeshInfo; +unit_t Unit; #endif -/* -if(Header.Unknown6Offset > 0) { - FSeek(Header.Unknown6Offset); - struct Unknown6 { - char __unk00[16]; - }Unknown6Info; -} - -if(Header.Unknown5Offset > 0) { - FSeek(Header.Unknown5Offset); - struct Unknown5 { - uint32 Count; - char __unk00[12]; - struct { - char __unk00[8]; - float textureWidth, textureHeight, textureDepth; - char __unk01[92]; - }Unknown5Data[Count]; - }Unknown5Info; -} - -if(Header.Unknown3Offset > 0) { - FSeek(Header.Unknown3Offset); - struct Unknown3 { - uint32 Count; - struct{ - char __unk00[159]; - }Unknown3Data[Count]; - }Unknown3Info; -} - -if(Header.Unknown4Offset > 0) { - FSeek(Header.Unknown4Offset); - struct Unknown4 { - uint32 Count; - struct { - uint32 __unk00[34]; - }Unknown4Data[Count]; - // 22192 bytes total?, 56B0 - }Unknown4Info; -} - -if(Header.Unknown1Offset > 0) { - FSeek(Header.Unknown1Offset); - struct Unknown1 { - uint32 Count; - uint32 __unk00; - }Unknown1Info; -} - -if(Header.Unknown2Offset > 0) { - FSeek(Header.Unknown2Offset); - struct Unknown2 { - struct { - uint32 __unk00[8]; - }Unknown2Data[3]; - }Unknown2Info; -} - -if(Header.UnknownOffset > 0) { - FSeek(Header.UnknownOffset); - struct Unknown { - uint32 count; - uint32 offsets[count]; - struct { - for (i=0; i < count; i++){ - FSeek(startof(UnknownInfo)+offsets[i]); - struct { - uint32 __unk00[17]; - }UnknownData; - } - }UnknownDatas; - }UnknownInfo; -} - - -if(Header.Unknown7Offset > 0) { - FSeek(Header.Unknown7Offset); - struct Unknown7 { - uint32 __unk00[2]; - }Unknown7Info; -} -*/ - #endif