.. | .. |
---|
321 | 321 | transform.setIdentity(); |
---|
322 | 322 | if ((body = bodies[BodyPart.BODYPART_LEFT_LOWER_ARM.ordinal()]) == null) |
---|
323 | 323 | body = bodies[BodyPart.BODYPART_LEFT_LOWER_ARM.ordinal()] = localCreateRigidBody(1f, 0, transform, shapes[BodyPart.BODYPART_LEFT_LOWER_ARM.ordinal()]); |
---|
324 | | - transform.origin.set(-(lowerarmlength/2 + upperarmlength + upperarmdist) * scale_ragdoll, 1.325f * scale_ragdoll, depth + zoffset); |
---|
325 | | - MatrixUtil.setEulerZYX(transform.basis, 0, 0, BulletGlobals.SIMD_HALF_PI); |
---|
| 324 | + transform.origin.set(-(lowerarmlength/2 + upperarmlength + upperarmdist) * scale_ragdoll, 1.325f * scale_ragdoll, depth + zoffset + scale_ragdoll * lowerarmlength / 2 * 0.5f); |
---|
| 325 | + MatrixUtil.setEulerZYX(transform.basis, BulletGlobals.SIMD_HALF_PI/4, 0, BulletGlobals.SIMD_HALF_PI); |
---|
326 | 326 | tmpTrans.mul(offset, transform); |
---|
327 | 327 | body.worldTransform.set(tmpTrans); |
---|
328 | 328 | body.getMotionState().setWorldTransform(tmpTrans); |
---|
.. | .. |
---|
351 | 351 | transform.setIdentity(); |
---|
352 | 352 | if ((body = bodies[BodyPart.BODYPART_RIGHT_LOWER_ARM.ordinal()]) == null) |
---|
353 | 353 | body = bodies[BodyPart.BODYPART_RIGHT_LOWER_ARM.ordinal()] = localCreateRigidBody(1f, 0, transform, shapes[BodyPart.BODYPART_RIGHT_LOWER_ARM.ordinal()]); |
---|
354 | | - transform.origin.set((lowerarmlength/2 + upperarmlength + upperarmdist) * scale_ragdoll, 1.325f * scale_ragdoll, depth + zoffset); |
---|
355 | | - MatrixUtil.setEulerZYX(transform.basis, 0, 0, -BulletGlobals.SIMD_HALF_PI); |
---|
| 354 | + transform.origin.set((lowerarmlength/2 + upperarmlength + upperarmdist) * scale_ragdoll, 1.325f * scale_ragdoll, depth + zoffset + scale_ragdoll * lowerarmlength / 2 * 0.5f); |
---|
| 355 | + MatrixUtil.setEulerZYX(transform.basis, BulletGlobals.SIMD_HALF_PI/4, 0, -BulletGlobals.SIMD_HALF_PI); |
---|
356 | 356 | tmpTrans.mul(offset, transform); |
---|
357 | 357 | body.worldTransform.set(tmpTrans); |
---|
358 | 358 | body.getMotionState().setWorldTransform(tmpTrans); |
---|