//Scripts void Start() { _collectablesText = _collectablesTextObject.GetComponent<Text>(); _collectablesTextObject.SetActive(false); _sonObject = GameObject.FindGameObjectsWithTag(GameTags.son); foreach (GameObject son in _sonObject) _sonCollectable = son.GetComponent<SonCollectable>(); }
//Scripts void Start() { _collectablesText = _collectablesTextObject.GetComponent <Text>(); _collectablesTextObject.SetActive(false); _sonObject = GameObject.FindGameObjectsWithTag(GameTags.son); foreach (GameObject son in _sonObject) { _sonCollectable = son.GetComponent <SonCollectable>(); } }