unity check if child exists code example
Example: unity check if child exists
Transform[] ts = GetComponentsInChildren();
foreach(Transform t in ts)
{
if(t != null)
{
//do something
}
}