diff options
| author | mat <27899617+mat-1@users.noreply.github.com> | 2023-11-19 22:07:38 -0600 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2023-11-19 22:07:38 -0600 |
| commit | 2c610826fc9f8e16897f52313faa8e0602d1dc3d (patch) | |
| tree | 5aad79ecab3b68511a10ebd7eba07af0bd8a5905 /azalea-world/src | |
| parent | 84e036ce3752ecf57904b0f5aff1f33d43e95a32 (diff) | |
| download | azalea-drasl-2c610826fc9f8e16897f52313faa8e0602d1dc3d.tar.xz | |
Replace azalea-nbt with simdnbt (#111)
* delete azalea-nbt and replace with simdnbt
* use simdnbt from crates.io
* remove serde dependency on azalea-registry
Diffstat (limited to 'azalea-world/src')
| -rwxr-xr-x | azalea-world/src/chunk_storage.rs | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/azalea-world/src/chunk_storage.rs b/azalea-world/src/chunk_storage.rs index 7301fdd1..ac81fd09 100755 --- a/azalea-world/src/chunk_storage.rs +++ b/azalea-world/src/chunk_storage.rs @@ -5,9 +5,9 @@ use crate::palette::PalettedContainerKind; use azalea_block::BlockState; use azalea_buf::{BufReadError, McBufReadable, McBufWritable}; use azalea_core::position::{BlockPos, ChunkBlockPos, ChunkPos, ChunkSectionBlockPos}; -use azalea_nbt::NbtCompound; use nohash_hasher::IntMap; use parking_lot::RwLock; +use simdnbt::owned::NbtCompound; use std::collections::hash_map::Entry; use std::str::FromStr; use std::{ @@ -323,11 +323,11 @@ impl Chunk { let mut heightmaps = HashMap::new(); for (name, heightmap) in heightmaps_nbt.iter() { - let Ok(kind) = HeightmapKind::from_str(name) else { + let Ok(kind) = HeightmapKind::from_str(&name.to_str()) else { warn!("Unknown heightmap kind: {name}"); continue; }; - let Some(data) = heightmap.as_long_array() else { + let Some(data) = heightmap.long_array() else { warn!("Heightmap {name} is not a long array"); continue; }; |
