diff options
| author | Jan Nils Ferner <contact@jnferner.com> | 2023-01-28 01:08:22 +0100 |
|---|---|---|
| committer | Jan Nils Ferner <contact@jnferner.com> | 2023-01-28 01:08:22 +0100 |
| commit | 3b537a20c27ed2c964737de72b00c422a74bcdff (patch) | |
| tree | 481f41693804be15d7d37a0b5193877a3b6b4a8d /src/control | |
| parent | 456c62e2ff28c16656febe4f5d388a879d709b6a (diff) | |
| download | rapier-3b537a20c27ed2c964737de72b00c422a74bcdff.tar.gz rapier-3b537a20c27ed2c964737de72b00c422a74bcdff.tar.bz2 rapier-3b537a20c27ed2c964737de72b00c422a74bcdff.zip | |
Remove unused variables
Diffstat (limited to 'src/control')
| -rw-r--r-- | src/control/character_controller.rs | 27 |
1 files changed, 12 insertions, 15 deletions
diff --git a/src/control/character_controller.rs b/src/control/character_controller.rs index a0771b6..72e3d77 100644 --- a/src/control/character_controller.rs +++ b/src/control/character_controller.rs @@ -193,8 +193,7 @@ impl KinematicCharacterController { let mut translation_remaining = desired_translation; - // Check if we are grounded at the initial position. - let grounded_at_starting_pos = self.detect_grounded_status_and_apply_friction( + self.detect_grounded_status_and_apply_friction( dt, bodies, colliders, @@ -298,19 +297,17 @@ impl KinematicCharacterController { } } - // If needed, and if we are not already grounded, snap to the ground. - //if grounded_at_starting_pos { - self.snap_to_ground( - bodies, - colliders, - queries, - character_shape, - &(Translation::from(result.translation) * character_pos), - &dims, - filter, - &mut result, - ); - //} + // If needed, snap to the ground. + self.snap_to_ground( + bodies, + colliders, + queries, + character_shape, + &(Translation::from(result.translation) * character_pos), + &dims, + filter, + &mut result, + ); // Return the result. result |
