Пример #1
0
    void Update()
    {
        mesh = transform.GetChild(0).gameObject;
        if (!mesh)
        {
            return;
        }
        CollectionBin bin = FindObjectOfType <CollectionBin>();

        if (!bin)
        {
            return;
        }
        mesh.SetActive(bin.keys == 3 && bin.present == 1 ? true : false);
    }
Пример #2
0
    void Update()
    {
        if (!active)
        {
            return;
        }
        if (!bin)
        {
            bin = GetComponentInChildren <CollectionBin>();
        }
        if (keysCreated < 3)
        {
            CreateKeys(3);
        }


        if (StopWatch.isRunning)
        {
            StopWatch.execute();
        }
    }