setLinearOffset method

void setLinearOffset(
  1. Vector2 linearOffset
)

Set the target linear offset, in frame A, in meters.

Implementation

void setLinearOffset(Vector2 linearOffset) {
  if (linearOffset.x != _linearOffset.x ||
      linearOffset.y != _linearOffset.y) {
    _bodyA.setAwake(true);
    _bodyB.setAwake(true);
    _linearOffset.setFrom(linearOffset);
  }
}