Hi!
So I want to find all available transforms on a buttonpress, and put them in an array to randomise a spawning point.

I want to make a spawning randomiser of a pipelines, but I need the transforms of those children.
Since it’s not one GameObject I can’t say ‘FindComponentInChildren’ or anything alike. All the children have tags to their name accordingly, so I can define when instantiating an object where it instantiated.
here’s my code:
GameObject[] HasTopTrans;
GameObject[] HasBottomTrans;
GameObject[] HasRightTrans;
GameObject[] HasLeftTrans;
public GameObject[] Arrrr;
public void OnClick()
{
//This would work, if the objects weren't children. It just collects all the transforms and puts
//them in one array. I'm using "using System.Linq" too.
HasTopTrans = GameObject.FindGameObjectsWithTag("Up");
HasBottomTrans = GameObject.FindGameObjectsWithTag("Down");
HasRightTrans = GameObject.FindGameObjectsWithTag("Right");
HasLeftTrans = GameObject.FindGameObjectsWithTag("Left");
Arrrr = HasTopTrans.Concat(HasBottomTrans).ToArray();
Arrrr = Arrrr.Concat(HasRightTrans).ToArray();
Arrrr = Arrrr.Concat(HasLeftTrans).ToArray();
}