diff --git a/src/physics.rs b/src/physics.rs index 4a1d5ed..6679486 100644 --- a/src/physics.rs +++ b/src/physics.rs @@ -500,6 +500,7 @@ impl MoveState{ }, _=>(), } + //this fixes falling through the ground when walking self.apply_to_body(body,touching,models,hitbox_mesh,style,camera,input_state); } //function to coerce &mut self into &self @@ -1388,6 +1389,8 @@ fn run_teleport_behaviour(wormhole:&Option,models }, None=>(), } + //just doing this to set the acceleration when surfing + state.move_state.apply_enum(&mut state.body,&state.touching,&data.models,&data.hitbox_mesh,&state.style,&state.camera,&state.input_state); }, (PhysicsCollisionAttributes::Intersect{intersecting: _,general},Collision::Intersect(intersect))=>{ //I think that setting the velocity to 0 was preventing surface contacts from entering an infinite loop