public void StopEffect(SoundName effect) { Transform audio = transform.Find("(Audio) " + effect.ToString()); if (audio != null) { BlockTools.Destroy(audio.gameObject); } }
IEnumerator Flow() { while (gameObject.activeInHierarchy) { if (transform.childCount > 0) { BlockTools.Destroy(transform.GetChild(0).gameObject); yield return(new WaitForSeconds(0.5f)); } else { yield return(null); } } }