GameObject.SetActiveRecursively Manual     Reference     Scripting  
Scripting > Runtime Classes > GameObject
GameObject.SetActiveRecursively

function SetActiveRecursively (state : bool) : void

Description

Sets the active state of this and all the game objects children to state.

JavaScripts
gameObject.SetActiveRecursively(true);

using UnityEngine;
using System.Collections;

public class example : MonoBehaviour {
void Awake() {
gameObject.SetActiveRecursively(true);
}
}

import UnityEngine
import System.Collections

class example(MonoBehaviour):

def Awake():
gameObject.SetActiveRecursively(true)