public IEnumerator OnUpdate() { yield return(new WaitForSeconds(1)); bool isFinished = false; ScreenFader.FadeInThen(() => { Juicer.ShakeCamera(0.5f); MessageController.AddMessage("yo."); MessageController.AddMessage("this is game peanutbutters."); MessageController.AddMessage("it goes great with game jams."); MessageController.AddMessage("you may have noticed the camera and music change. very easy to do with cinemachine and the juicer.", postAction: () => { GameConductor.CameraStateTrigger("NextState"); }); MessageController.AddMessage("these bois are moving with the simplemover script. it's an easy way to get some nice motion with little effort. useful for pickups, simple enemies, etc.", postAction: () => { GameConductor.CameraStateTrigger("NextState"); }); MessageController.AddMessage("this is a fun script called textjacker. it jacks up text.", postAction: () => { GameConductor.CameraStateTrigger("NextState"); }); MessageController.AddMessage("after this message finishes, the game will transition to the next game state. a basic player object will be created.", postAction: () => isFinished = true); }); do { yield return(new WaitForSeconds(1)); } while (!isFinished); }
public IEnumerator OnUpdate() { GameConductor.ResetPlayer(); GameConductor.UnfreezePlayer(); GameConductor.PerformScheduleCallbacks(11, 0); _daycard.SetActive(true); _daycard.GetComponentInChildren <Text>().text = DataDump.Get <string>("Day") + " evening"; yield return(new WaitForSeconds(4)); _daycard.SetActive(false); bool isFinished = false; ScreenFader.FadeInThen(() => { GameConductor.FreezePlayer(); MessageController.AddMessage("Hmm. Haven't seen you around before.", postAction: () => GameConductor.CameraStateTrigger("NextState")); MessageController.AddMessage("Welcome to The Deja Brew."); MessageController.AddMessage("... oh? You need a place to stay?"); MessageController.AddMessage("We got a room in the back when you're ready to hit the hay."); MessageController.AddMessage("Literally -- it's all we got.", postAction: () => { GameConductor.CameraStateTrigger("FocusPlayer"); GameConductor.UnfreezePlayer(); isFinished = true; }); MessageController.AddMessage("Enjoy the band and meet some of the regulars. We usually get a few characters in here."); }); do { yield return(new WaitForSeconds(1)); } while (!isFinished); }