@Override
  public void startGame() {
    setGameDuration(GAME_DURATION_MS);

    // set starting points of textview
    updatePointsTextView(0);

    super.startGame();
    updateToGameMode();
  }
  @Override
  void endGame() {
    // convert to seconds
    int remainingTimeInSeconds = (int) super.getRemainingTimeMs() / 1000;
    this.points = (int) (this.points + remainingTimeInSeconds);

    if (this.won) savePoints();

    dialogGameOver();

    super.endGame();

    updateToTrainMode();

    reset();
  }
 private void checkIfButtonClickedIsCorrectAnswer(int index) {
   boolean response = false;
   if (respRadioButton[index].getText().equals(test.getResponse())) {
     response = true;
   } else {
     response = false;
   }
   super.showAnimationAnswer(response);
   // only create new Question if user has right input
   if (this.gameMode) {
     if (response) {
       gameModeControl();
       newQuestion();
     } else if (totalFails < 3) {
       totalFails++;
       partialPoints = partialPoints - REST_FOR_FAIL;
     } else {
       partialPoints = 0;
       gameModeControl();
       newQuestion();
     }
   }
 }
 @Override
 public void cancelGame() {
   super.cancelGame();
   updateToTrainMode();
 }