Пример #1
0
 // Start is called before the first frame update
 void Start()
 {
     if (tManager == null)
     {
         var go = GameObject.FindGameObjectWithTag("Tag");
         if (go != null)
         {
             tManager = go.GetComponent <TTTManager>();
         }
     }
 }
Пример #2
0
        public void Init()
        {
            CommandClickField = new CommandClickField(this);
            CommandReset      = new CommandReset(this);
            TTTManager        = new TTTManager();

            Coll          = TTTManager.InitCollToBlank();
            CollVisual    = TTTManager.InitCollVisualToBlank();
            currentPlayer = false;
            LastWinner    = null;
            TTTManager.SetCollVisual(Coll, CollVisual);
        }
Пример #3
0
    // Start is called before the first frame update
    void Start()
    {
        Man = transform.gameObject.AddComponent <TTTManager>();

        Debug.Log("TEST 01: " + Test01());
        Debug.Log("TEST 02: " + Test02());
        Debug.Log("TEST 03: " + Test03());

        Debug.Log("TEST 04: " + Test04());

        Debug.Log("TEST 05: " + Test05());
        Debug.Log("TEST 06: " + Test06());
    }
Пример #4
0
    // Start is called before the first frame update
    void Start()
    {
        GameObject temp = GameObject.FindGameObjectWithTag("Grid");

        if (temp == null)
        {
            //Debug.Log("Could not find object tagged \"Grid\", AI shutting down");
            this.enabled = false;
            return;
        }
        Grid = temp.GetComponent <TTTManager>();
        if (Grid == null)
        {
            //Debug.Log("Could not find Grid Component, AI shutting down");
            this.enabled = false;
            return;
        }

        _timeRemaining = SecondsToChange;
    }