How to find child of a GameObject or the script attached to child GameObject via script
Finding child GameObject by index: You can get the first child of a GameObject with the GetChild function. GameObject originalGameObject = GameObject.Find(“MainObj”); GameObject child = originalGameObject.transform.GetChild(0).gameObject; You can get other children by providing index number of the child GameObject such as 1,2,3, to the GetChild function. and if its a child of a child in … Read more