Esempio n. 1
0
    public void activation()
    {
        QnsCall();
        ReadEntries();
        LogGameItems();

        //Player two's turn
        if (x1 == false)
        {
            O1.GetComponent <CanvasGroup> ().blocksRaycasts = true;
            O1.SetActive(false);
            O2.GetComponent <CanvasGroup> ().blocksRaycasts = true;
            O2.SetActive(false);
            O3.GetComponent <CanvasGroup> ().blocksRaycasts = true;
            O3.SetActive(false);
            O4.GetComponent <CanvasGroup> ().blocksRaycasts = true;
            O4.SetActive(false);
            T1.SetActive(false);
            HideOptBox1();

            P1.SetActive(true);
            P2.SetActive(true);
            P3.SetActive(true);
            P4.SetActive(true);
            T2.SetActive(true);
            ShowOptBox2();
            tr2.resetClock2();

            optionTxt2();
            x1 = true;
        }

        //Player one's turn
        else
        {
            P1.GetComponent <CanvasGroup> ().blocksRaycasts = true;
            P1.SetActive(false);
            P2.GetComponent <CanvasGroup> ().blocksRaycasts = true;
            P2.SetActive(false);
            P3.GetComponent <CanvasGroup> ().blocksRaycasts = true;
            P3.SetActive(false);
            P4.GetComponent <CanvasGroup> ().blocksRaycasts = true;
            P4.SetActive(false);
            T2.SetActive(false);
            HideOptBox2();


            O1.SetActive(true);
            O2.SetActive(true);
            O3.SetActive(true);
            O4.SetActive(true);
            T1.SetActive(true);
            ShowOptBox1();
            tr1.resetClock1();

            optionTxt1();
            x1 = false;
        }
    }
Esempio n. 2
0
 void Start()
 {
     N = 1;
     T1.SetActive(true);
     T2.SetActive(false);
     T3.SetActive(false);
     T4.SetActive(false);
 }
Esempio n. 3
0
    public void Reset()
    {
        T1.GetComponent <UIButton> ().isEnabled = false;
//		T2.GetComponent<UIButton> ().isEnabled = true;

//		T11.GetComponent<UIButton> ().isEnabled = false;
//		T22.GetComponent<UIButton> ().isEnabled = true;
        T1.SetActive(true);
        T2.SetActive(false);
    }
 // Update is called once per frame
 void Update()
 {
     if (Playerloss.BonusActive)
     {
         T1.SetActive(false);
         T2.SetActive(false);
     }
     if (!Playerloss.BonusActive)
     {
         T1.SetActive(true);
         T2.SetActive(true);
     }
 }
Esempio n. 5
0
    void Start()
    {
        GameObject mc = GameObject.Find("MusicManager");

        Destroy(mc);
        randQns();
        QnsCall();
        ReadEntries();
        LogGameItems();

        optionTxt1();
        HideOptBox2();
        T2.SetActive(false);
        x1 = false;
    }
    // Use this for initialization
    void Start()
    {
        currentLvl = GameObject.FindGameObjectWithTag("Lvl").GetComponent <CurrentLevel>().lvl;

        if (currentLvl == 0)
        {
            T1.SetActive(true);
        }
        else if (currentLvl == 1)
        {
            T2.SetActive(true);
        }
        else if (currentLvl == 2)
        {
            T3.SetActive(true);
        }

        tiles = Tiles.GetComponent <Tiles>();
        GenerateLevel();
        tiles.LevelIsGenerated();
    }
Esempio n. 7
0
    // Update is called once per frame
    void Update()
    {
        if (N > 4)
        {
            N = 1;
        }

        if (N == 1)
        {
            T1.SetActive(true);
            T2.SetActive(false);
            T3.SetActive(false);
            T4.SetActive(false);
        }
        else if (N == 2)
        {
            T1.SetActive(false);
            T2.SetActive(true);
            T3.SetActive(false);
            T4.SetActive(false);
        }
        else if (N == 3)
        {
            T1.SetActive(false);
            T2.SetActive(false);
            T3.SetActive(true);
            T4.SetActive(false);
        }
        else if (N == 4)
        {
            T1.SetActive(false);
            T2.SetActive(false);
            T3.SetActive(false);
            T4.SetActive(true);
        }
    }
 void Start()
 {
     Playerloss = FindObjectOfType <ThePlayerLoss>();
     T1.SetActive(true);
     T2.SetActive(true);
 }