/** * @param float $kilometer */ protected function move($kilometer) { $this->TrackdataLoop->moveToDistance($kilometer); if (!is_null($this->RouteLoop)) { $this->RouteLoop->goToIndex($this->TrackdataLoop->index()); } }
/** * @param int $seconds */ protected function moveToTime($seconds) { $this->TrackdataLoop->moveToTime($seconds); if (!is_null($this->RouteLoop)) { $this->RouteLoop->goToIndex($this->TrackdataLoop->index()); } }
/** * Check for pause */ protected function checkForPause() { if (!is_null($this->Trackdata) && $this->Trackdata->hasPauses()) { if ($this->PauseIndex < $this->Trackdata->pauses()->num() && $this->Trackdata->pauses()->at($this->PauseIndex)->time() <= $this->Trackdata->at($this->TrackdataLoop->index(), Trackdata\Entity::TIME)) { $this->addCurrentPauseIcon(); $this->PathShouldBreak = true; $this->PauseIndex++; } } elseif (!Configuration::ActivityView()->routeBreak()->never() && $this->RouteLoop->calculatedStepDistance() > $this->PauseLimit) { $this->addCurrentSegment(); } }