protected virtual IEnumerable <ProxyContentFile> CreateContentFiles( IEnumerable <ProxyFileTableEntry> fileTableEntries, IEnumerable <ProxyPathTableEntry> pathTableEntries) { var files = new List <ProxyContentFile>(); var pathTableEntriesDict = pathTableEntries.ToDictionary(x => x.Hash, new ByteArrayComparer()); foreach (var entry in fileTableEntries) { var newFile = new ProxyContentFile(); newFile.Hash = entry.Hash; newFile.Length = entry.Length; newFile.Offset = entry.Offset; newFile.Padding = entry.Padding; newFile.Unknown = entry.Unknown; newFile.Path = pathTableEntriesDict[newFile.Hash].Path; files.Add(newFile); } return(files); }
/// <summary> /// /// </summary> /// <param name="file"></param> public void LoadContent(ProxyContentFile file) { LoadContent(new ProxyContentFile[] { file }); }