private async Task SelectStart() { await fade.FadeOutRoutine("white"); scrollView.gameObject.SetActive(true); await fade.FadeInRoutine("white"); await scrollView.ScrollRoutine(); await fade.FadeOutRoutine("black"); Global.Instance().Data.Party = new Party(); await RecruitAsync(recruitLeader); await RecruitAsync(recruitFollower); await RecruitAsync(recruitFollower); await RecruitAsync(recruitFollower); await Task.Delay(1000); Global.Instance().StartCoroutine(Global.Instance().Serialization.StartGameRoutine(defaultMapKey, defaultMapTarget)); }
public async Task <bool> RetryAsync(Battle battle) { var text = type.textbox.text; type.textbox.text = ""; await fade.FadeOutRoutine("white"); gameObject.SetActive(true); await fade.FadeInRoutine("white"); await type.TypeRoutine(text, false); await expander.ShowRoutine(); while (true) { var command = await choiceSelector.SelectCommandAsync(); switch (command) { case "end": await fade.FadeOutRoutine("black"); SceneManager.LoadScene("Title"); return(false); case "retry": await fade.FadeOutRoutine("white"); battle.Reset(); gameObject.SetActive(false); await fade.FadeInRoutine("white"); return(true); } } }