From 608ccb8e54454460a1b41a456f99b16d70fb5913 Mon Sep 17 00:00:00 2001 From: mat Date: Sun, 12 Jan 2025 05:07:53 +0000 Subject: fix panic on bot disconnect --- azalea-physics/src/lib.rs | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) (limited to 'azalea-physics/src/lib.rs') diff --git a/azalea-physics/src/lib.rs b/azalea-physics/src/lib.rs index 6ea4e946..c626dcdf 100644 --- a/azalea-physics/src/lib.rs +++ b/azalea-physics/src/lib.rs @@ -109,10 +109,8 @@ pub fn ai_step( if !physics.is_in_lava() || physics.on_ground() && fluid_height <= fluid_jump_threshold { - if physics.on_ground() - || in_water - && fluid_height <= fluid_jump_threshold - && physics.no_jump_delay == 0 + if (physics.on_ground() || in_water && fluid_height <= fluid_jump_threshold) + && physics.no_jump_delay == 0 { jump_from_ground( &mut physics, -- cgit v1.2.3