public void lose() { GameObject go = GameObject.Find("Win"); LogoFadeIn other = (LogoFadeIn)go.GetComponent(typeof(LogoFadeIn)); other.startFading(MovingTextManager.FadeType.In); endScene = true; }
void OnTriggerEnter2D(Collider2D col) { if (col.gameObject.tag == "InvisibleBoxCollider") { MovingTextManager.Instance.FadeText("InitialCutsceneText", MovingTextManager.FadeType.Out); GameObject go = GameObject.Find("logo_main"); LogoFadeIn other = (LogoFadeIn)go.GetComponent(typeof(LogoFadeIn)); other.startFading(MovingTextManager.FadeType.In); } MovingTextManager.Instance.FadeText("StartGameText", MovingTextManager.FadeType.In); }