aboutsummaryrefslogtreecommitdiff
path: root/azalea/src/pathfinder/world.rs
diff options
context:
space:
mode:
authormat <git@matdoes.dev>2025-06-11 16:55:33 +1100
committermat <git@matdoes.dev>2025-06-11 16:55:33 +1100
commit9b0bd29db4faa9d94df0cec472346b814e7efcb9 (patch)
tree4f681b5143eb5ebe69a0b5b53125ea7509f8026a /azalea/src/pathfinder/world.rs
parent2a6ac0764fe9975f9b16d495ce773e4ae1f097e0 (diff)
downloadazalea-drasl-9b0bd29db4faa9d94df0cec472346b814e7efcb9.tar.xz
take BlockPos instead of &BlockPos in all function arguments
Diffstat (limited to 'azalea/src/pathfinder/world.rs')
-rw-r--r--azalea/src/pathfinder/world.rs16
1 files changed, 8 insertions, 8 deletions
diff --git a/azalea/src/pathfinder/world.rs b/azalea/src/pathfinder/world.rs
index 3ec95136..e9337503 100644
--- a/azalea/src/pathfinder/world.rs
+++ b/azalea/src/pathfinder/world.rs
@@ -625,13 +625,13 @@ mod tests {
.chunks
.set(&ChunkPos { x: 0, z: 0 }, Some(Chunk::default()), &mut world);
partial_world.chunks.set_block_state(
- &BlockPos::new(0, 0, 0),
+ BlockPos::new(0, 0, 0),
azalea_registry::Block::Stone.into(),
&world,
);
partial_world
.chunks
- .set_block_state(&BlockPos::new(0, 1, 0), BlockState::AIR, &world);
+ .set_block_state(BlockPos::new(0, 1, 0), BlockState::AIR, &world);
let ctx = CachedWorld::new(Arc::new(RwLock::new(world.into())), BlockPos::default());
assert!(!ctx.is_block_pos_passable(BlockPos::new(0, 0, 0)));
@@ -646,13 +646,13 @@ mod tests {
.chunks
.set(&ChunkPos { x: 0, z: 0 }, Some(Chunk::default()), &mut world);
partial_world.chunks.set_block_state(
- &BlockPos::new(0, 0, 0),
+ BlockPos::new(0, 0, 0),
azalea_registry::Block::Stone.into(),
&world,
);
partial_world
.chunks
- .set_block_state(&BlockPos::new(0, 1, 0), BlockState::AIR, &world);
+ .set_block_state(BlockPos::new(0, 1, 0), BlockState::AIR, &world);
let ctx = CachedWorld::new(Arc::new(RwLock::new(world.into())), BlockPos::default());
assert!(ctx.is_block_pos_solid(BlockPos::new(0, 0, 0)));
@@ -667,19 +667,19 @@ mod tests {
.chunks
.set(&ChunkPos { x: 0, z: 0 }, Some(Chunk::default()), &mut world);
partial_world.chunks.set_block_state(
- &BlockPos::new(0, 0, 0),
+ BlockPos::new(0, 0, 0),
azalea_registry::Block::Stone.into(),
&world,
);
partial_world
.chunks
- .set_block_state(&BlockPos::new(0, 1, 0), BlockState::AIR, &world);
+ .set_block_state(BlockPos::new(0, 1, 0), BlockState::AIR, &world);
partial_world
.chunks
- .set_block_state(&BlockPos::new(0, 2, 0), BlockState::AIR, &world);
+ .set_block_state(BlockPos::new(0, 2, 0), BlockState::AIR, &world);
partial_world
.chunks
- .set_block_state(&BlockPos::new(0, 3, 0), BlockState::AIR, &world);
+ .set_block_state(BlockPos::new(0, 3, 0), BlockState::AIR, &world);
let ctx = CachedWorld::new(Arc::new(RwLock::new(world.into())), BlockPos::default());
assert!(ctx.is_standable_at_block_pos(BlockPos::new(0, 1, 0)));