diff options
| author | Sébastien Crozet <developer@crozet.re> | 2022-01-16 16:40:59 +0100 |
|---|---|---|
| committer | Sébastien Crozet <developer@crozet.re> | 2022-01-16 16:52:40 +0100 |
| commit | 0703e5527fd95d86bb6621e61dbcb1a6e7f9329a (patch) | |
| tree | 806e7d950015875ebfcca5520784aea6e7c5ae10 /examples3d | |
| parent | 4454a845e98b990abf3929ca46b59d0fca5a18ec (diff) | |
| download | rapier-0703e5527fd95d86bb6621e61dbcb1a6e7f9329a.tar.gz rapier-0703e5527fd95d86bb6621e61dbcb1a6e7f9329a.tar.bz2 rapier-0703e5527fd95d86bb6621e61dbcb1a6e7f9329a.zip | |
Fix some solver issues
- Fix the wrong codepath taken by the solver for contacts involving a collider without parent.
- Properly adress the non-linear treatment of the friction direction
- Simplify the sleeping strategy
- Add an impulse resolution multiplier
Diffstat (limited to 'examples3d')
| -rw-r--r-- | examples3d/debug_articulations3.rs | 14 |
1 files changed, 6 insertions, 8 deletions
diff --git a/examples3d/debug_articulations3.rs b/examples3d/debug_articulations3.rs index 26831ef..3b75a21 100644 --- a/examples3d/debug_articulations3.rs +++ b/examples3d/debug_articulations3.rs @@ -66,17 +66,15 @@ pub fn init_world(testbed: &mut Testbed) { let mut impulse_joints = ImpulseJointSet::new(); let mut multibody_joints = MultibodyJointSet::new(); - let rigid_body = RigidBodyBuilder::new_dynamic().build(); - let collider = ColliderBuilder::cuboid(30.0, 0.01, 30.0) // Vector::y_axis()) - .translation(vector![0.0, -3.0, 0.0]) + let collider = ColliderBuilder::cuboid(30.0, 0.01, 30.0) + .translation(vector![0.0, -3.02, 0.0]) .rotation(vector![0.1, 0.0, 0.1]) .build(); - let handle = bodies.insert(rigid_body); - colliders.insert_with_parent(collider, handle, &mut bodies); + colliders.insert(collider); - let rigid_body = RigidBodyBuilder::new_static().build(); - let collider = ColliderBuilder::cuboid(30.0, 0.01, 30.0) // Vector::y_axis()) - .translation(vector![0.0, -3.02, 0.0]) + let rigid_body = RigidBodyBuilder::new_dynamic().build(); + let collider = ColliderBuilder::cuboid(30.0, 0.01, 30.0) + .translation(vector![0.0, -3.0, 0.0]) .rotation(vector![0.1, 0.0, 0.1]) .build(); let handle = bodies.insert(rigid_body); |
