Example #1
0
 //Closes question panel and lowers the number of startObjects.
 //Will return to game unless startObjects reaches 0, in which case the results display.
 public void nextQuestion()
 {
     if (quizPopup.getCanvasLength() >= 2)
     {
         int q = quizPopup.getQuestionN();
         quizPopup.setCanvas(q, false);
         quizPopup.setCanvas(++q, true);
         quizPopup.reduceCanvasLength();
         quizPopup.nextQuestionN();
     }
     else
     {
         transform.parent.tag = "Placed";
         rs.reportSelf();
         quizPopup.isClickable = false;
         quizPopup.answered    = true;
         quizPopup.setAlpha();
         if (statTracking.identifyLevel() != "Q5")
         {
             levelManager.noObjections = true;                 //Make other panels openable again.
         }
         this.gameObject.SetActive(false);
         //Reduce the number of objects remaining by one
         levelManager.startObjects--;
         levelManager.addobjPlaced();
     }
 }
    //Closes question Panel and lowers the number of startObjects.
    //Will return to game unless startObjects reaches 0, in which case the results display.
    public void nextQuestion()
    {
        if (quizPopup.getCanvasLength() >= 2)
        {
            int q = quizPopup.getQuestionN();
            quizPopup.setCanvas(q, false);
            quizPopup.setCanvas(++q, true);
            quizPopup.reduceCanvasLength();
            quizPopup.nextQuestionN();
        }
        else
        {
            transform.parent.tag = "Placed";
            rs.reportSelf();
            quizPopup.isClickable = false;
            quizPopup.answered    = true;
            quizPopup.setAlpha();
            if (SceneManager.GetActiveScene().name != "UpperArm6B")
            {
                levelManager.noObjections = true;                 //Make other panels openable again.
            }
            levelManager.canvasOpen = false;
            this.gameObject.SetActive(false);

            //Reduce the number of objects remaining by one.
            levelManager.startObjects--;
            //levelManager.addMuscPlaced ();
        }
    }