public static AnimatedCongratulationController Instance() { if (!animatedCongratulationController) { animatedCongratulationController = FindObjectOfType(typeof(AnimatedCongratulationController)) as AnimatedCongratulationController; if (!animatedCongratulationController) { Debug.LogError("There needs to be one active ObjectiveManager script on a GameObject in your scene."); } } return(animatedCongratulationController); }
private void Awake() { instance = this; }