Пример #1
0
    // [SerializeField]
    // private bool _IsThisTutorial;


    private void Start()
    {
        if (_ClosedFolderSprite != null)
        {
            _FolderImg.sprite = _ClosedFolderSprite;
        }
        _SoundOnClick  = this.GetComponent <AudioSource>();
        _XbuttonScript = Resources.FindObjectsOfTypeAll <XbuttonScript>()[0];
        _VerdictScript = Resources.FindObjectsOfTypeAll <VerdictScript>()[0];
        _pos           = transform.localPosition;
        //_canvasObj = GameObject.FindGameObjectWithTag("Canvas");
        // if (_IsThisTutorial)
        //     _TutorialUI = GameObject.FindGameObjectWithTag("TUTORIAL");
        _contentObj = GameObject.FindGameObjectWithTag("CONTENT");
        _scrollObj  = GameObject.FindGameObjectWithTag("SCROLL");
        _bin        = GameObject.FindGameObjectWithTag("BIN");
        if (_bin != null)
        {
            _binScript = _bin.GetComponent <BinScript>();
        }

        /* if (_canvasObj != null)
         * {
         *   _image = _imgObj.GetComponent<Image>();
         *   _text = _imgObj.GetComponentInChildren<Text>();
         * }
         * else
         *   Debug.Log("Error in Evidence Script");
         */
        DropEvidenceScript[] fooGroup = Resources.FindObjectsOfTypeAll <DropEvidenceScript>();
        if (fooGroup.Length > 0)
        {
            _foo1 = fooGroup[0];
            _foo2 = fooGroup[1];
            _foo3 = fooGroup[2];
        }
    }