diff options
| author | mat <git@matdoes.dev> | 2025-09-28 13:10:04 -0545 |
|---|---|---|
| committer | mat <git@matdoes.dev> | 2025-09-28 13:10:04 -0545 |
| commit | 2c8b7c5c2c9297273abfba8f7743f1bc25f166b1 (patch) | |
| tree | 3d3aded400100c136287fa59293ce26c61644d00 /azalea/src/auto_tool.rs | |
| parent | e2ed19c1ed92f0dccc881d835d9ac6e0f7f834c0 (diff) | |
| download | azalea-drasl-2c8b7c5c2c9297273abfba8f7743f1bc25f166b1.tar.xz | |
upgrade bevy to 0.17.0-rc.2
Diffstat (limited to 'azalea/src/auto_tool.rs')
| -rw-r--r-- | azalea/src/auto_tool.rs | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/azalea/src/auto_tool.rs b/azalea/src/auto_tool.rs index 3d8d6e36..e7eb614d 100644 --- a/azalea/src/auto_tool.rs +++ b/azalea/src/auto_tool.rs @@ -19,12 +19,12 @@ pub trait AutoToolClientExt { impl AutoToolClientExt for Client { fn best_tool_in_hotbar_for_block(&self, block: BlockState) -> BestToolResult { - let mut ecs = self.ecs.lock(); - let (inventory, physics, fluid_on_eyes) = - self.query::<(&Inventory, &Physics, &FluidOnEyes)>(&mut ecs); - let menu = &inventory.inventory_menu; - - accurate_best_tool_in_hotbar_for_block(block, menu, physics, fluid_on_eyes) + self.query_self::<(&Inventory, &Physics, &FluidOnEyes), _>( + |(inventory, physics, fluid_on_eyes)| { + let menu = &inventory.inventory_menu; + accurate_best_tool_in_hotbar_for_block(block, menu, physics, fluid_on_eyes) + }, + ) } async fn mine_with_auto_tool(&self, block_pos: BlockPos) { |
