protected static void SetActiveRecursivelyEffect(GameObject target, bool bActive) { NcEffectBehaviour[] componentsInChildren = target.GetComponentsInChildren <NcEffectBehaviour>(true); NcEffectBehaviour[] array = componentsInChildren; for (int i = 0; i < array.Length; i++) { NcEffectBehaviour ncEffectBehaviour = array[i]; ncEffectBehaviour.OnSetActiveRecursively(bActive); } }