readSimulationPose method

(Vector3, Quaternion) readSimulationPose()

The body's pose fresh from the simulation, unlike the node transform this is exact mid-step state (useful inside fixedUpdate, where the interpolated node transform lags).

Implementation

(Vector3, Quaternion) readSimulationPose() {
  final handle = _handle;
  if (handle == null) {
    return (
      node.globalTransform.getTranslation(),
      Quaternion.fromRotation(node.globalTransform.getRotation()),
    );
  }
  return _sim!.readBodyPose(handle);
}