Skip to content

Releases: ValveResourceFormat/ValvePak

2.0.1

09 May 09:59
Compare
Choose a tag to compare

Full Changelog: 2.0.0...2.0.1

  • Do not require _dir suffix in chunked vpks
  • Removed System.Security.Cryptography.Algorithms
  • Added ContinuousIntegrationBuild

2.0.0

22 Mar 11:14
2.0.0
Compare
Choose a tag to compare

Full Changelog: 1.8.0...2.0.0

  • .NET 8.0 is now required
  • Removed FindEntry overloads
  • Reduced allocations in FindEntry
  • Updated logo

1.8.0

13 Feb 18:37
1.8.0
Compare
Choose a tag to compare

Full Changelog: 1.7.0...1.8.0

  • GetMemoryMappedStreamIfPossible will read files smaller or equal to 4096 bytes into memory instead of memory mapping.
  • GetMemoryMappedStreamIfPossible now supports memory mapping files in non-split packages if the package was read from a FileStream or when using Read(file path).
  • CRC32 is now calculated with System.IO.Hashing

1.7.0

07 Jan 15:40
1.7.0
Compare
Choose a tag to compare

Full Changelog: 1.6.2...1.7.0

  • CRC32 mismatch exceptions will now print expected and actual values.
  • Added GetMemoryMappedStreamIfPossible to get package entry file mmap for split vpks

1.6.2

23 Nov 17:19
2bb5d1a
Compare
Choose a tag to compare

Full Changelog: 1.6.1...1.6.2

  • Added ReadEntry overload with user provided byte array
  • Allow VPKs where MD5 section is not exactly 48 bytes

1.6.1

08 Sep 10:21
1.6.1
Compare
Choose a tag to compare

Full Changelog: https://github.com/SteamDatabase/ValvePak/compare/1.6.0...1.6.1?w=1

  • Removed IsSignatureValid call from VerifyHashes
  • Fixed slashes in AddFile
  • Added VerifyChunkHashes
  • Added VerifyFileChecksums

1.6.0

05 Sep 09:55
1.6.0
Compare
Choose a tag to compare

Full Changelog: https://github.com/SteamDatabase/ValvePak/compare/1.5.0...1.6.0?w=1

  • Added Write() method that will save to a vpk file (non-chunked)
  • Added AddFile() and RemoveFile() methods
  • Optimized hash and signature verification to work on stream rather than reading all data into memory

1.5.0

14 Jul 15:27
1.5.0
Compare
Choose a tag to compare

Full Changelog: https://github.com/SteamDatabase/ValvePak/compare/1.4.0...1.5.0?w=1

  • Added OptimizeEntriesForBinarySearch(StringComparison)
    • Call this before Read()
    • This sorts the entries, which allows FindEntry(string fileName) to use BinarySearch to find the entries much faster
    • This also allows FindEntry to search case insensitively if desired
    • This is experimental, and maybe removed in the future
  • FindEntry(string directory, string fileName) and FindEntry(string directory, string fileName, string extension) overloads have been deprecated

1.4.0

22 Mar 21:56
1.4.0
Compare
Choose a tag to compare

Full Changelog: 1.3.0...1.4.0

  • Added support for Counter-Strike 2 vpks
  • IsSignatureValid now returns true if there no signature available

1.3.0

29 Apr 16:51
Compare
Choose a tag to compare

Full Changelog: 1.2.0...1.3.0

  • IsDirVPK and HeaderSize properties are now public.
  • Use the original file name when opening file stream.
  • Optimized ReadEntries to be faster and allocate less.

Test on Dota 2's pak01_dir.vpk on Ryzen 3700x:

Method Mean Error StdDev Gen 0 Gen 1 Gen 2 Allocated
Old 1,106.5 ms 21.83 ms 31.31 ms 112000 30000 4000 877 MB
New 217.7 ms 4.11 ms 4.57 ms 7666 4333 1333 59 MB