public function countActivityPoints(Activity $activity) { $points = 0; $round = $activity->getRound(); $discr = $round->getDiscr(); switch ($discr) { case 'rush': $points += $this->getPointForFoundables($activity->getFoundForms()); $points += $activity->getComboPoints(); break; case 'conquer': $points += $this->getPointForObjectives($activity); break; } return floor($points); }