mirror of
https://github.com/MihailRis/voxelcore.git
synced 2026-10-06 11:31:49 +00:00
inventory regions, minor refactor
This commit is contained in:
parent
a57fba4fa4
commit
49fdcdfb27
29 changed files with 259 additions and 160 deletions
|
|
@ -99,10 +99,7 @@ bool files::write_json(fs::path filename, const dynamic::Map* obj, bool nice) {
|
|||
}
|
||||
|
||||
bool files::write_binary_json(fs::path filename, const dynamic::Map* obj, bool compression) {
|
||||
auto bytes = json::to_binary(obj);
|
||||
if (compression) {
|
||||
bytes = gzip::compress(bytes.data(), bytes.size());
|
||||
}
|
||||
auto bytes = json::to_binary(obj, compression);
|
||||
return files::write_bytes(filename, bytes.data(), bytes.size());
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue