Ejemplo n.º 1
0
    // other variables all inherited from GameController

    // Start is called before the first frame update
    void Start()
    {
        dataController = FindObjectOfType <DataController>();
        level          = dataController.GetDifficulty();
        isTutorial     = dataController.GetCurrentTut();
        equation       = dataController.GetCurrentEquationData(level, isTutorial);
        inputTimer     = 0;
        won            = false;


        if (level < 5)
        {
            BothSideOperations bso = FindObjectOfType <BothSideOperations>();
            bso.gameObject.SetActive(false);
        }

        if (isTutorial)
        {
            levelText.text = "Tutorial " + level.ToString();
        }
        else
        {
            levelText.text = "Stage " + level.ToString();
        }

        currentlyDragging = false;
        roundActive       = true;

        // set up seesaw according to equation
        SetUpSeesaw();
        numInitialBrackets = equation.lhs.numBrackets + equation.rhs.numBrackets;
    }
 public void Start()
 {
     operationController = FindObjectOfType <BothSideOperations>();
 }