Joint set iteration: also yield the joint handle.

This commit is contained in:
Crozet Sébastien
2020-10-05 16:51:16 +02:00
parent 9c22e59416
commit d8dfd864a4
2 changed files with 11 additions and 7 deletions

View File

@@ -66,10 +66,10 @@ impl NPhysicsWorld {
}
for joint in joints.iter() {
let b1 = BodyPartHandle(rapier2nphysics[&joint.body1], 0);
let b2 = BodyPartHandle(rapier2nphysics[&joint.body2], 0);
let b1 = BodyPartHandle(rapier2nphysics[&joint.1.body1], 0);
let b2 = BodyPartHandle(rapier2nphysics[&joint.1.body2], 0);
match &joint.params {
match &joint.1.params {
JointParams::FixedJoint(params) => {
let c = FixedConstraint::new(
b1,