Ejemplo n.º 1
0
    IEnumerator EndDialogue()
    {
        if (theCutScene.CheckCutScene())
        {
            SettingUI(false);
            CutSceneManager.isFinished = false;
            StartCoroutine(theCutScene.CutSceneCoroutine(null, false));
            yield return(new WaitUntil(() => CutSceneManager.isFinished));
        }
        if (theSlide.CheckSlide())
        {
            SettingUI(false);
            SlideManager.isFinished = false;
            StartCoroutine(theSlide.DisAppearSlide());
            yield return(new WaitUntil(() => SlideManager.isFinished));
        }
        DisappearObjects(true);

        AppearOrDisappearObjects();
        yield return(new WaitUntil(() => Spin.isFinished));

        StartCoroutine(theSprite.HalfSpriteDisappearCoroutine());
        yield return(new WaitUntil(() => SpriteManager.isFinish));



        isDialogue   = false;
        contextCount = 0;
        lineCount    = 0;
        dialogues    = null;
        theCam.CameraTargetting(null, 0.05f, true, true);



        isNext = false;

        SettingUI(false);
        yield return(new WaitUntil(() => !InteractionControler.isInteract));

        if (go_NextEvent != null)
        {
            InteractionEvent tIE = go_NextEvent.GetComponent <InteractionEvent>();
            if (tIE.CheckEvent())
            {
                go_NextEvent.SetActive(true);
                go_NextEvent = null;
            }
            else
            {
                theIC.SettingUI(true);
            }
        }
        else
        {
            theIC.SettingUI(true);
        }
    }
Ejemplo n.º 2
0
    public IEnumerator CutSceneCoroutine(string p_CutSceneName, bool p_isShow)
    {
        SplashManager.isfinish = false;
        StartCoroutine(theSplash.FadeOut(true, false, true));
        yield return(new WaitUntil(() => SplashManager.isfinish));

        if (theSlide.CheckSlide())
        {
            StartCoroutine(theSlide.DisAppearSlide());
        }

        if (p_isShow)
        {
            Sprite t_Sprite = Resources.Load <Sprite>("CutScenes/" + p_CutSceneName);
            if (t_Sprite != null)
            {
                img_CutScene.gameObject.SetActive(true);
                img_CutScene.sprite = t_Sprite;
                theCam.CameraTargetting(null, 0.05f, true, false);
            }
            else
            {
                Debug.LogError("잘못된 컷신 CG파일 이름입니다");
            }
        }
        else
        {
            img_CutScene.gameObject.SetActive(false);
        }


        SplashManager.isfinish = false;
        StartCoroutine(theSplash.FadeIn(true, false));
        yield return(new WaitUntil(() => SplashManager.isfinish));

        yield return(new WaitForSeconds(0.5f));

        isFinished = true;
    }