Skip to content

Commit b9e3433

Browse files
committed
should allow grounding with no up movement
1 parent 89e3d76 commit b9e3433

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/control/character_controller.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -318,7 +318,7 @@ impl KinematicCharacterController {
318318
result: &mut EffectiveCharacterMovement,
319319
) -> Option<(ColliderHandle, TOI)> {
320320
if let Some(snap_distance) = self.snap_to_ground {
321-
if result.translation.dot(&self.up) < -1.0e-5 {
321+
if result.translation.dot(&self.up) <= 0.0 {
322322
let snap_distance = snap_distance.eval(dims.y);
323323
let offset = self.offset.eval(dims.y);
324324
if let Some((hit_handle, hit)) = queries.cast_shape(

0 commit comments

Comments
 (0)