revert() {
    const nodeIds = Object.keys(this.previousStates);
    const nodes = this.body.nodes;
    const velocities = this.physicsBody.velocities;
    this.referenceState = {};

    for (let i = 0; i < nodeIds.length; i++) {
      const nodeId = nodeIds[i];
      if (nodes[nodeId] !== undefined) {
        if (nodes[nodeId].options.physics === true) {
          this.referenceState[nodeId] = {
            positions: { x: nodes[nodeId].x, y: nodes[nodeId].y },
          };
          velocities[nodeId].x = this.previousStates[nodeId].vx;
          velocities[nodeId].y = this.previousStates[nodeId].vy;
          nodes[nodeId].x = this.previousStates[nodeId].x;
          nodes[nodeId].y = this.previousStates[nodeId].y;
        }
      } else {
        delete this.previousStates[nodeId];
      }
    }
  }
Revert the simulation one step. This is done so after stabilization, every new start of the simulation will also say stabilized.