Paul Chote
f69c6ab3fb
Update SharpZipLib to 1.1.0.
...
The default code page has been changed to UTF8
so our workarounds are no longer needed.
2019-03-30 20:47:22 +01:00
abcdefg30
cadbd0d9ab
Change the year number in all cs headers from 2018 to 2019
2019-01-26 23:15:21 +01:00
Arular101
8a60918841
Update copyright notice year to 2018
2018-01-17 00:47:34 +01:00
RoosterDragon
ca01a1f186
Presize MemoryStream when possible.
...
Also use GetBuffer when we know we have presized the stream to the exact required size to prevent a needless copy.
2017-12-19 00:59:11 +01:00
Paul Chote
93fcfbb131
Fix ReadWriteZipFile crashing on update.
2017-07-18 00:10:07 +02:00
Paul Chote
daf8f8d956
Throw a FileNotFoundException if source zip file isn't found.
2017-07-08 23:22:44 +02:00
Paul Chote
f7c57cfc6f
Fix crash when loading read-only ReadWriteZipFiles.
2017-07-08 16:45:44 +01:00
RoosterDragon
297f4ad9ed
Ensure we set ZipConstants.DefaultCodePage by using a helper method.
...
We were currently dealing with this terrible global variable in FileSystem/ZipFile.cs previously, but other parts of the code such as DownloadPackageLogic were creating these files too, and may not have executed the static ctors that fixed the encoding yet.
2017-07-05 22:45:15 +01:00
Paul Chote
df40d38b91
Rework read/write zip file loading/saving.
2017-05-29 12:20:32 +02:00
Paul Chote
0222ea675c
Implement mod-defined package loaders.
2017-05-07 13:25:38 +01:00
Taryn Hill
43317e0f5d
Update copyright notice year to 2017
2016-12-31 23:46:13 -06:00
Matthias Mailänder
2ab82664e3
Dispose the intermediate Stream after copying it to pkgStream.
2016-07-26 22:14:42 +02:00
Matthias Mailänder
96d9a01f76
Dispose pkgStream.
2016-07-03 10:26:56 +02:00
Paul Chote
c706e68b73
Rework zip file updating.
2016-07-01 21:58:26 +01:00
Paul Chote
be52c1cb72
Properly use the virtual filesystem for map loading and saving.
2016-02-28 19:27:33 +00:00
Paul Chote
617113fa86
Rework IReadWritePackage interface.
2016-02-28 10:18:50 +00:00
Paul Chote
e71225496b
Clarify GPL version.
2016-02-21 16:30:48 +00:00
Paul Chote
b396965fd9
Update licence header year.
2016-02-21 16:27:31 +00:00
Paul Chote
00945dc9ef
Tidy IReadOnlyPackage interface and implementations.
2016-02-01 22:49:12 +00:00
Paul Chote
feab81bdea
Remove IReadOnlyPackage.Priority.
...
Priority is now determined solely by order in mod.yaml
(later packages take priority of earlier ones).
2016-02-01 22:49:11 +00:00
Paul Chote
91c25d7b84
Remove unused Package.(Classic|Crc)Hashes.
2016-01-29 19:56:16 +00:00
RoosterDragon
8e89a6a696
Simplify names, remove unused usings, remove redundant casts.
2016-01-17 21:35:36 +00:00
Paul Chote
f8d0b97e8d
Split IPackage into IReadOnlyPackage and IReadWritePackage.
2016-01-16 10:37:21 +00:00
Pavel Penev
45382d193a
Rename IFolder to IPackage
2016-01-11 21:53:48 +02:00
Matthias Mailänder
51468c60ed
use UTF8 instead of system locale code page
2016-01-02 09:08:21 +01:00
Pavel Penev
d08a400565
Add a context argument to package files contructors
2015-12-14 03:42:25 +02:00
RoosterDragon
bfe1804bf6
Fix some spellings.
2015-11-27 16:19:59 +00:00
RoosterDragon
ce73bb909e
Make IFolder interface inherently IDisposable.
...
Fix up implementations to ensure they dispose any stream they acquire, and ensure the constructor will not leave a stream open if it fails. Dispose folders when unmounting them in GlobalFileSystem.
2015-07-23 22:31:20 +01:00
Matthias Mailänder
9261f685a7
fix a null reference exception
2015-06-10 06:48:10 +02:00
abcdefg30
8ca61aa917
Updated all year numbers
2015-01-09 21:18:05 +01:00
Hellhake
fa72e04042
Remove BOM
2015-01-01 22:51:12 +01:00
Alexander Fast
070d00c678
Fixes year numbers in license text in file headers.
2014-08-21 11:27:52 +02:00
RoosterDragon
a598a01108
Fixed IDisposable implementation and usage.
...
- Implement IDisposable interface correctly, with sealed classes where possible for simplicity.
- Add using statement around undisposed local variables.
2014-06-10 11:23:55 +01:00
RoosterDragon
531e3b7861
Fixes to StreamExts.
...
- Almost all calls to Stream.Read were broken. These have been patched to all go through ReadBytes which itself has been fixed to function correctly. The key thing to note is that Stream.Read is very much allowed to return less than the requested number of bytes. If this happens and you're not checking the return result, you'll be working with partially initialized arrays and really bad stuff happens when you do that.
- Call CopyTo rather than copying between streams manually.
- Peek and ReadUInt8 have been changed to avoid a pointless array allocation which is significant overhead for such simple calls.
2014-06-07 00:49:25 +01:00
ForNeVeR
06671c8aa4
Fix encoding problems with ZipFile.
...
Without setting the DefaultCodePage it may cause problems on systems without 866 code page installed.
2014-05-17 17:11:29 +07:00
Paul Chote
4935266945
Merge FileFormats dll into Game and reorganise namespaces.
2014-04-17 01:20:47 +12:00