Пример #1
0
    IEnumerator StartIntro()
    {
        pageCount = 0;

        image.sprite = pages[pageCount];
        FadeTool.FadeIn(0.4f);
        yield return(new WaitForSeconds(4f));

        FadeTool.FadeOut(0.4f);
        yield return(new WaitForSeconds(0.8f));

        pageCount++;
        while (pageCount < pages.Count)
        {
            image.sprite = pages[pageCount];
            FadeTool.FadeIn(0.4f);
            yield return(new WaitForSeconds(2f));

            FadeTool.FadeOut(0.4f);
            yield return(new WaitForSeconds(0.7f));

            pageCount++;
        }
        FadeTool.FadeIn(0.01f);
        anim.Play("start");
        yield return(new WaitForSeconds(2f));

        Off();
    }
Пример #2
0
    /*
     * IEnumerator CreditBySpeedRoutine()
     * {
     *  bar.value = 1f;
     *  while (bar.value > 0f)
     *  {
     *      bar.value -= Time.deltaTime * scrollSpeed;
     *      yield return null;
     *  }
     *  FadeTool.FadeOutIn(0.5f, 0.5f, ShowImage);
     * }
     */

    IEnumerator BadCreditRoutine()
    {
        pageCount = 0;

        image.sprite = badPages[pageCount];
        FadeTool.FadeIn(0.4f);
        yield return(new WaitForSeconds(4f));

        FadeTool.FadeOut(0.4f);
        yield return(new WaitForSeconds(0.8f));

        pageCount++;
        while (pageCount < badPages.Count)
        {
            image.sprite = badPages[pageCount];
            FadeTool.FadeIn(0.4f);
            yield return(new WaitForSeconds(2f));

            FadeTool.FadeOut(0.4f);
            yield return(new WaitForSeconds(0.7f));

            pageCount++;
        }
    }