private void ShowStars() { foreach (GameObject star in instantiatedStars) { star.GetComponent <Renderer>().enabled = true; StarSparkle starSparkle = star.GetComponent <StarSparkle>(); starSparkle.Show(); starSparkle.FadeIn(); } }
public void changeToDay() { if (isDay) { return; } isDay = true; foreach (GameObject star in instantiatedStars) { StarSparkle starSparkle = star.GetComponent <StarSparkle>(); starSparkle.FadeOut(); //CircleCollider2D collider = star.GetComponent<CircleCollider2D>(); //collider.enabled = false; Invoke("ResetStars", 5f); } }