public override void InitFromRawDecompressed(byte[] decompressedBytes) { using (var reader = new BinaryReader(new MemoryStream(decompressedBytes))) { this.Resource = Read_WorldChunkDefinition(reader); } }
private WorldChunkDef Read_WorldChunkDefinition(BinaryReader reader) { var result = new WorldChunkDef(); result.Version = ReadVersion(reader, 3, 0x1410E3B80); if (result.Version == 2) { result.Version2 = ReadVersion(reader, 3, 0x1410E3B80); } result.ClusterInstantiations = Read_List(reader, Read_ClusterInstantiation, 1, 0x1416E9730); result.RenderChunk = Read_RenderChunk(reader); result.Version3 = ReadVersion(reader, 2, 0x1416E9750); result.EnvironmentId = ReadUUID(reader); if (result.Version3 >= 2) { result.AudioChunk = Read_List(reader, ReadUUID, 1, 0x1416F0360); } return(result); }