update method

void update(
  1. double dt
)

Updates path following movement.

Implementation

void update(double dt) {
  if (_currentPath.isNotEmpty) {
    if (!_comp.moveToPosition(_currentPath[_currentIndex])) {
      _goToNextPosition();
    }
  }
}