Buenas noches ftejada.
Sí puedes crear gameObjects mediante código, la manera sería, instanciar el GameObject, y luego cambiar su "padre" para que sea el objeto que tu quieres, de esa manera, el nuevo gameObject quedará como hijo del gameObject antiguo.
Sería algo así:
Sí puedes crear gameObjects mediante código, la manera sería, instanciar el GameObject, y luego cambiar su "padre" para que sea el objeto que tu quieres, de esa manera, el nuevo gameObject quedará como hijo del gameObject antiguo.
Sería algo así:
Transform padre; //lo pones en el inspector.
void Start ()
{
http://docs.unity3d.com/ScriptReference/GameObject.html" rel="external nofollow"> GameObject hijo = new http://docs.unity3d.com/ScriptReference/GameObject.html" rel="external nofollow">GameObject("NombreDelHijo");
hijo.transform.parent = padre;
}