obligaron
780015bfd4
Fix warnings in MpqWriter
2 years ago
Gleb Mazovetskiy
16a6fc62e1
Deduplicate some of the MPQ handling
...
Reuse libmpq functions where possible instead of our own.
3 years ago
Gleb Mazovetskiy
74755c8be7
Remove utils/stdcompat/cstddef.hpp
3 years ago
Gleb Mazovetskiy
1a1a282d9a
Use C FILE instead of C++ streams throughout
...
Reduces binary size by ~2 KiB and may improve compatibility with oddball
systems (e.g. PS2).
3 years ago
Gleb Mazovetskiy
6d274c9547
`UNPACKED_SAVES`: Saves without MPQs
...
Reduces rg99 binary size by ~70 KiB.
3 years ago
obligaron
7afe7d2a70
Save Methods in loadsave gets MpqWriter passed
4 years ago
Gleb Mazovetskiy
8d74b99c72
MpqWriter: Cleanups and renames
...
I've spent some time understanding how the `MpqWriter` works
and cleaned it up a bit and renamed some variables for clarity.
1. Fixes all signedness and clang-tidy warnings.
2. Renames variables, structs, and methods for clarity.
3. Marks structs used for I/O as packed.
4. Adds comments in a few places.
5. Eliminates recursion from `MpqWriter::AllocBlock` (a clang-tidy
warning).
4 years ago
Gleb Mazovetskiy
7e1fea6f76
clang-format all files in {Source,test}/
...
Also includes a few manual tweaks to comments and newlines for better results.
Co-authored-by: Anders Jenbo <anders@jenbo.dk>
4 years ago
Gleb Mazovetskiy
720d210d95
utils/mpq* -> mpq/*
4 years ago
Gleb Mazovetskiy
23406b6fc5
Replace mpqapi.h with the MpqWriter class
...
This is a cleanup, heading in the direction of allowing us to reuse
some of the code between reading and writing MPQs.
4 years ago