diff --git a/CGameAreaResource.bt b/CGameAreaResource.bt index 7e6345e..a5eafa6 100644 --- a/CGameAreaResource.bt +++ b/CGameAreaResource.bt @@ -36,23 +36,27 @@ struct ProductionWorkStages { struct GameAreaHeader { ChunkDescriptor chunk; - GUID id_a; - ushort unk1; - ushort unk2; - bool unk3; - GUID id_b; - GUID id_c; - GUID id_d; - GUID id_e; - GUID id_f; - ProductionWorkStages workStages; + if (isDKCTF) + { + uint16 unk; + } + else + { + GUID id_a; + ushort unk1; + ushort unk2; + bool unk3; + GUID id_b; + GUID id_c; + GUID id_d; + GUID id_e; + GUID id_f; + ProductionWorkStages workStages; + } }; struct ScriptPerformanceGroupResourceData { - uint unk1; - if (unk1) { - char unkData[unk1]; - } + CStringFixed name; GUID unk2; uchar unk3; ushort count; @@ -130,18 +134,23 @@ struct LoadUnit { FormDescriptor form; local int start = FTell(); ChunkDescriptor chunk; - uint unk1; - if (unk1) - char unkData[unk1]; - GUID id1; - GUID id2; - ushort unk2; - uint unk3; - if (unk3) - char unkData2[unk3]; - uint unk4; - if (unk4) - char unkData3[unk4]; + CStringFixed name; + GUID id; + if (isDKCTF) + { + uint16 unk; + } + else + { + GUID id2; + ushort unk2; + uint unk3; + if (unk3) + char unkData2[unk3]; + uint unk4; + if (unk4) + char unkData3[unk4]; + } ChunkDescriptor lresChunk; uint guidCount; if (guidCount) { @@ -181,9 +190,38 @@ struct STRP { struct ScriptData { FormDescriptor form; + if (isDKCTF) + { + FormDescriptor form2; + } ChunkDescriptor chunk; - uint propertiesCount; - uint instanceDataCount; + if (isDKCTF) + { + uint32 componentTypeHash; + GUID componentGUID; + CStringFixed componentNmae; + uint16 connectionCount; + if (connectionCount) { + struct { + GUID connection1; + GUID connection2; + GUID componentID; + uint16 unk; + bool unk2; + bool unk3; + } connections; + } + uint16 scriptLinkCount; + if (scriptLinkCount) { + struct { + GUID linkID; + GUID componentID; + bool unk; + } connections; + } + } + //uint propertiesCount; + //uint instanceDataCount; uint dataLen; char data[dataLen * 0x18]; struct { @@ -198,15 +236,31 @@ struct ScriptData { }; struct LayerHeader { - int name_length; - char name[name_length]; + CStringFixed name; GUID id; - int unk; + if (isDKCTF) + { + uint16 unk; + ushort count; + if (count) { + struct { + GUID guid; + } guids[count+1]; + } + bool unk2; + } + else + { + int unk; + } }; struct Layer { FormDescriptor layers_form; - FormDescriptor form; + if (!isDKCTF) + { + FormDescriptor form; + } ChunkDescriptor header_chunk; LayerHeader header; }; @@ -216,14 +270,24 @@ struct CGameAreaResource { GameAreaHeader game_area_header; PerformanceGroups performance_groups; GeneratedObjectMap generated_object_map; - Docks docks; - BakedLightning baked_lighting; - ChunkDescriptor load_unit_chunk; - short num_load_units; - LoadUnit load_units[num_load_units]; - STRP strp; - ScriptData script_data; + if (!isDKCTF) + { + Docks docks; + BakedLightning baked_lighting; + ChunkDescriptor load_unit_chunk; + short num_load_units; + LoadUnit load_units[num_load_units]; + STRP strp; + ScriptData script_data; + } + else + { + //while (FTell() != start + form.size) { + LoadUnit load_unit[6]; + //} + } Layer layer; + ScriptData script_data; }; #endif // _CGAMEAREARESOURCE \ No newline at end of file