GameObject to Variable to GameObject and add string?

private GameObject planet;

Ok I turned this gameObject into a variable called “planet”.

planet = GameObject.Find(SystemSizeSetup*.name);*

Then I want to test to see if it worked and it worked.
print (planet.transform.localScale);
but adding a string to it, does not work.
print ((planet + “Cloud”).transform.localScale);
I have cloud, lava, lightning that I would like to add to each planet object, how would you go about doing that? I need to find the shortcuts so its easier to read the scripts.
Having a code like this is easy to read and search for errors.

if (Satellite) Satellite.transform.RotateAround(Planet.transform.localPosition, Satellite.transform.up, SatelliteSpeed);

Have a look at Transform.Find.

In this example, I create a list of planets, and a list of children of the planets by first finding all transforms in the scene, then telling the code that planets are transforms without parents, but that have children. The list of children is found by getting the children of those planets.

C# Example

using UnityEngine;
using System.Collections;
using System.Collections.Generic;

public class example : MonoBehaviour 
{
	Object[] Transforms;
	List<Transform> planets;
	List<Transform> children;
	
	void Awake()
	{
		planets = new List<Transform>();
		children = new List<Transform>();
		Transforms = GameObject.FindObjectsOfType(typeof(Transform));
		
		foreach(Transform T in Transforms)
		{
			if(T.parent == null && T.childCount > 0)
			{
				planets.Add(T);
			}
		}
		
		foreach(Transform planet in planets)
		{
			if(planet.Find ("Cloud1"))
			{
				Transform cloud1 = planet.Find ("Cloud1");
				children.Add (cloud1);
			}
		}
		
		if(children.Count > 0)
		{
			foreach(Transform cloud in children)
			{
				print (cloud.localScale);	
			}
		}
	}
}