Skip to content

Commit

Permalink
Add ability to write anvil chunks (#516)
Browse files Browse the repository at this point in the history
# Objective

- Follow on from #510 by adding the ability to write and delete chunks
in anvil files.

# Solution

- Users can change the compression method and whether to write oversized
chunks, in case they want to write anvil files compatible with older
versions of Minecraft.
- `LruCache::try_get_or_insert_mut` is something I have [pull
requested](jeromefroe/lru-rs#178) to `lru`, we
can switch to that once it's merged.
  • Loading branch information
Earthcomputer authored Sep 3, 2023
1 parent 7b21704 commit 78a12d4
Show file tree
Hide file tree
Showing 3 changed files with 602 additions and 75 deletions.
1 change: 1 addition & 0 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -112,6 +112,7 @@ bevy_log = { version = "0.11" }
bevy_mod_debugdump = { version = "0.8.0", default-features = false }
bevy_utils = { version = "0.11" }
bitfield-struct = "0.5.3"
bitvec = "1.0.1"
byteorder = "1.4.3"
bytes = "1.2.1"
cesu8 = "1.1.0"
Expand Down
2 changes: 2 additions & 0 deletions crates/valence_anvil/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,8 @@ parsing = ["dep:num-integer", "dep:valence_server"]
[dependencies]
bevy_app = { workspace = true, optional = true }
bevy_ecs = { workspace = true, optional = true }
bitfield-struct.workspace = true
bitvec.workspace = true
byteorder.workspace = true
flate2.workspace = true
flume = { workspace = true, optional = true }
Expand Down
Loading

0 comments on commit 78a12d4

Please sign in to comment.