From fb20d72ee29de9311a81aec6eb9f02fd2aa35fc4 Mon Sep 17 00:00:00 2001 From: Sébastien Crozet Date: Sun, 20 Feb 2022 12:55:00 +0100 Subject: Joint API and joint motors improvements --- examples3d/convex_decomposition3.rs | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) (limited to 'examples3d/convex_decomposition3.rs') diff --git a/examples3d/convex_decomposition3.rs b/examples3d/convex_decomposition3.rs index 6daf4d7..33c1611 100644 --- a/examples3d/convex_decomposition3.rs +++ b/examples3d/convex_decomposition3.rs @@ -24,11 +24,9 @@ pub fn init_world(testbed: &mut Testbed) { let ground_size = 50.0; let ground_height = 0.1; - let rigid_body = RigidBodyBuilder::new_static() - .translation(vector![0.0, -ground_height, 0.0]) - .build(); + let rigid_body = RigidBodyBuilder::new_static().translation(vector![0.0, -ground_height, 0.0]); let handle = bodies.insert(rigid_body); - let collider = ColliderBuilder::cuboid(ground_size, ground_height, ground_size).build(); + let collider = ColliderBuilder::cuboid(ground_size, ground_height, ground_size); colliders.insert_with_parent(collider, handle, &mut bodies); /* @@ -88,13 +86,11 @@ pub fn init_world(testbed: &mut Testbed) { let y = (igeom / width) as f32 * shift + 4.0; let z = k as f32 * shift; - let body = RigidBodyBuilder::new_dynamic() - .translation(vector![x, y, z]) - .build(); + let body = RigidBodyBuilder::new_dynamic().translation(vector![x, y, z]); let handle = bodies.insert(body); for shape in &shapes { - let collider = ColliderBuilder::new(shape.clone()).build(); + let collider = ColliderBuilder::new(shape.clone()); colliders.insert_with_parent(collider, handle, &mut bodies); } } -- cgit