private void ProcessEntries() { foreach (WebFileEntry entry in Metadata.Entries.Values) { FileScheme scheme = GameCollection.ReadScheme(m_stream, entry.Offset, entry.Size, FilePath, entry.NameOrigin); AddScheme(scheme); } }
private void ProcessEntries() { foreach (BundleFileEntry entry in Metadata.Entries.Values) { FileEntryOffset offset = m_entryStreams[entry]; FileScheme scheme = GameCollection.ReadScheme(offset.Stream, offset.Offset, entry.Size, FilePath, entry.NameOrigin); AddScheme(scheme); } }
private void ReadPre530Data(Stream stream, long metadataOffset) { foreach (BundleFileEntry entry in Metadata.Entries) { byte[] buffer = new byte[entry.Size]; stream.Position = metadataOffset + entry.Offset; stream.ReadBuffer(buffer, 0, buffer.Length); FileScheme scheme = GameCollection.ReadScheme(buffer, FilePath, entry.NameOrigin); AddScheme(scheme); } }
private void ReadRawWebData(Stream stream, long metadataOffset) { foreach (Node entry in Metadata.DirectoryInfo.Nodes) { byte[] buffer = new byte[entry.Size]; stream.Position = metadataOffset + entry.Offset; stream.ReadBuffer(buffer, 0, buffer.Length); FileScheme scheme = GameCollection.ReadScheme(buffer, FilePath, entry.PathOrigin); AddScheme(scheme); } }
private void Read530Data(Stream stream, long headerSize) { if (Header.Flags.IsMetadataAtTheEnd()) { stream.Position = headerSize; } using (BundleFileBlockReader blockReader = new BundleFileBlockReader(stream, Metadata)) { foreach (BundleFileEntry entry in Metadata.Entries) { SmartStream entryStream = blockReader.ReadEntry(entry); FileScheme scheme = GameCollection.ReadScheme(entryStream, FilePath, entry.NameOrigin); AddScheme(scheme); } } }
private void ReadScheme(Stream stream) { using (EndianReader reader = new EndianReader(stream, EndianType.LittleEndian)) { Header.Read(reader); Metadata.Read(reader); } foreach (WebFileEntry entry in Metadata.Entries) { byte[] buffer = new byte[entry.Size]; stream.Position = entry.Offset; stream.ReadBuffer(buffer, 0, buffer.Length); FileScheme scheme = GameCollection.ReadScheme(buffer, FilePath, entry.NameOrigin); AddScheme(scheme); } }
private void ReadFileStreamData(Stream stream, long basePosition, long headerSize) { if (Header.FileStream.Flags.IsBlocksInfoAtTheEnd()) { stream.Position = basePosition + headerSize; } using (BundleFileBlockReader blockReader = new BundleFileBlockReader(stream, Metadata.BlocksInfo)) { foreach (Node entry in Metadata.DirectoryInfo.Nodes) { SmartStream entryStream = blockReader.ReadEntry(entry); FileScheme scheme = GameCollection.ReadScheme(entryStream, FilePath, entry.PathOrigin); AddScheme(scheme); } } }