From 1dec4f5664c08a9571c0fdbdb81088f1fde821db Mon Sep 17 00:00:00 2001 From: Ubuntu Date: Fri, 2 Sep 2022 17:22:15 +0000 Subject: make collision test work* --- azalea-world/src/lib.rs | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'azalea-world/src') diff --git a/azalea-world/src/lib.rs b/azalea-world/src/lib.rs index 32b4b82f..2d65ebc8 100644 --- a/azalea-world/src/lib.rs +++ b/azalea-world/src/lib.rs @@ -52,6 +52,11 @@ impl Dimension { self.chunk_storage.replace_with_packet_data(pos, data) } + pub fn set_chunk(&mut self, pos: &ChunkPos, chunk: Option) -> Result<(), BufReadError> { + self[pos] = chunk.map(|c| Arc::new(Mutex::new(c))); + Ok(()) + } + pub fn update_view_center(&mut self, pos: &ChunkPos) { self.chunk_storage.view_center = *pos; } -- cgit v1.2.3