public function DDLinesQuestion::getMaximumScore in Quiz 8.4
Get the maximum possible score for this question.
Overrides QuizQuestion::getMaximumScore
File
- question_types/
quiz_ddlines/ lib/ Drupal/ quiz_ddlines/ DDLinesQuestion.php, line 193 - The main classes for the quiz_ddlines question type.
Class
- DDLinesQuestion
- Extension of QuizQuestion.
Namespace
Drupal\quiz_ddlinesCode
public function getMaximumScore() {
// 1 point per correct hotspot location
$ddlines_elements = json_decode($this->node->ddlines_elements);
$max_score = isset($ddlines_elements->elements) ? sizeof($ddlines_elements->elements) : 0;
return $max_score;
}