update method

  1. @override
void update()
override

Update all the equations with data.

Implementation

@override
void update() {
  final bodyA = this.bodyA;
  final bodyB = this.bodyB;
  final x = equationX;
  final y = equationY;
  final z = equationZ;

  // Rotate the pivots to world space
  bodyA.quaternion.vmult(pivotA, x.ri);
  bodyB.quaternion.vmult(pivotB, x.rj);

  y.ri.copy(x.ri);
  y.rj.copy(x.rj);
  z.ri.copy(x.ri);
  z.rj.copy(x.rj);
}