private void MoveNext() { if (_folowingMove.IsMoving) { return; } MapPosition nextPosition = TryGetNextPosition(_currentPosition); if (nextPosition.Equals(_currentPosition)) { StopMove?.Invoke(); return; } _currentPosition = nextPosition; Vector3 scenePosition = _navigator.ToScenePosition(_currentPosition); _folowingMove.Move(scenePosition); StartMoveNext?.Invoke(); }
protected void OnStopMove() { StopMove?.Invoke(); }