Exemplo n.º 1
0
    /// <summary>
    /// チュートリアルダイアログを表示
    /// </summary>
    private void showTutorialDialog(int dialog_index)
    {
        m_IsShowingTutorialDialog = true;
        TutorialDialog.FLAG_TYPE flag_type = TutorialDialog.FLAG_TYPE.BATTLE;
        switch (dialog_index)
        {
        case 1:
            flag_type = TutorialDialog.FLAG_TYPE.BATTLE1;
            break;

        case 2:
            flag_type = TutorialDialog.FLAG_TYPE.BATTLE2;
            break;

        case 3:
            flag_type = TutorialDialog.FLAG_TYPE.BATTLE3;
            break;

        case 4:
            flag_type = TutorialDialog.FLAG_TYPE.BATTLE4;
            break;
        }
        TutorialDialog.Create()
        .SetTutorialType(flag_type)
        .Show(() =>
        {
            m_IsNextCommand           = true;
            m_IsShowingTutorialDialog = false;
        }
              );
    }
Exemplo n.º 2
0
    public void OnClick()
    {
        TutorialDialog dialog = TutorialDialog.Create();

        dialog.SetTutorialType(TutorialDialog.FLAG_TYPE.UNIT_PARTY_SELECT);
        dialog.Show(() => {
            Debug.Log("TutorialCarousel Completed");
        });
    }
Exemplo n.º 3
0
    public void OnShowCarousel_Scratch()
    {
        TutorialDialog.Create().
        SetTutorialType(TutorialPart.NORMAL02.ConvertToTutorialFlagType()).
        Show(
            () =>
        {
#if BUILD_TYPE_DEBUG
            Debug.Log("TutorialCarousel Completed");
#endif
            m_Info.EnableBackKey();
            TutorialFSM.Instance.SendFsmNextEvent();
        });
    }
Exemplo n.º 4
0
    /// <summary>
    /// チュートリアルダイアログを表示
    /// </summary>
    private void showFirstTutorialDialog(TutorialDialog.FLAG_TYPE flagType, System.Action finishAction)
    {
        bool is_already_show = LocalSaveManagerRN.Instance.GetIsShowTutorialDialog(flagType);

        if (is_already_show == false)
        {
            TutorialDialog.Create()
            .SetTutorialType(flagType)
            .Show(finishAction);
        }
        else
        {
            finishAction();
        }
    }
Exemplo n.º 5
0
    public void OnShowCarousel_UnitBuildUp()
    {
        SendStep(
            408,
            () =>
        {
            TutorialDialog.Create().
            SetTutorialType(TutorialPart.BUILDUP.ConvertToTutorialFlagType()).
            Show(
                () =>
            {
#if BUILD_TYPE_DEBUG
                Debug.Log("TutorialCarousel Completed");
#endif
                TutorialFSM.Instance.SendFsmNextEvent();
            });
        });
    }
Exemplo n.º 6
0
    public IEnumerator OnPageInBefor()
    {
        while (m_GlobalMenu.getNextPageSeq().PageSwitchEventEnableBefore())
        {
            yield return(null);
        }

        // 機能チュートリアルの表示
        TutorialDialog.FLAG_TYPE flagType = m_GlobalMenu.NextSeq.ConvertToTutorialFlagType();
        if (flagType != TutorialDialog.FLAG_TYPE.NONE && flagType != TutorialDialog.FLAG_TYPE.ALL)
        {
            bool isTutorial = (LocalSaveManagerRN.Instance.GetIsShowTutorialDialog(flagType) == false);
            if (isTutorial)
            {
#if BUILD_TYPE_DEBUG
                Debug.LogError(string.Format("チュートリアルを表示する FLAG_TYPE:{0}", flagType.ToString()));
#endif
                TutorialDialog.Create().SetTutorialType(flagType).Show(() =>
                {
                    isTutorial = false;
                });
            }
            while (isTutorial)
            {
#if BUILD_TYPE_DEBUG
                Debug.Log("IN_TUTORIAL");
#endif
                yield return(null);
            }
        }

        while (!m_GlobalMenu.getNextPageSeq().IsStart)
        {
            yield return(null);
        }

        m_GlobalMenu.getNextPageSeq().PageSwitchTriger(true, false, m_GlobalMenu.Back);

        GlobalMenuManagerFSM.Instance.SendFsmEvent("DO_NEXT");
    }
Exemplo n.º 7
0
    public void OnHeroSelectGuide()
    {
        Dialog newDialog = Dialog.Create(DialogType.DialogOK);

        newDialog.SetDialogTextFromTextkey(DialogTextType.Title, "tutorial_master_result_01_title");
        newDialog.SetDialogTextFromTextkey(DialogTextType.MainText, "tutorial_master_result_01_main");
        newDialog.SetDialogTextFromTextkey(DialogTextType.OKText, "common_button1");
        newDialog.SetDialogEvent(DialogButtonEventType.OK, new System.Action(() =>
        {
            TutorialManager.SendStep(
                4,
                () =>
            {
                TutorialDialog.Create().SetTutorialType(TutorialDialog.FLAG_TYPE.UNIT_HERO).Show();
                m_select = false;
                SetUpButtons();

                TutorialHeroSelectFSM.Instance.SendFsmNextEvent();
            });
        }));
        newDialog.DisableCancelButton();
        newDialog.Show();
    }
Exemplo n.º 8
0
    private void openScoreInfo()
    {
        if (m_ScoreDialog != null ||
            ServerApi.IsExists)
        {
            return;
        }

        SoundUtil.PlaySE(SEID.SE_MENU_OK);

        m_ScoreDialog = ScoreEventDialog.Create(SceneObjReferMainMenu.Instance.m_MainMenuGroupCamera.GetComponent <Camera>());

        int[] event_ids = new int[scoreEventList.Count];
        for (int i = 0; i < scoreEventList.Count; i++)
        {
            event_ids[i] = (int)scoreEventList[i].event_id;
        }
        ServerDataUtilSend.SendPacketAPI_GetUserScoreInfo(event_ids)
        .setSuccessAction((data) =>
        {
            RecvGetUserScoreInfo scoreInfo = data.GetResult <RecvGetUserScoreInfo>();
            if (scoreInfo != null &&
                scoreInfo.result != null &&
                scoreInfo.result.score_infos != null)
            {
                for (int i = 0; i < scoreInfo.result.score_infos.Length; i++)
                {
                    PacketStructUserScoreInfo Info = scoreInfo.result.score_infos[i];
                    if (Info == null)
                    {
                        continue;
                    }

                    MasterDataScoreEvent scoreEventMaster = scoreEventList.Find((m) => m.event_id == Info.event_id);
                    if (scoreEventMaster == null)
                    {
                        continue;
                    }

                    m_ScoreDialog.addScoreInfo(Info, scoreEventMaster);
                }


                bool isTutorial = (LocalSaveManagerRN.Instance.GetIsShowTutorialDialog(TutorialDialog.FLAG_TYPE.SCORE) == false);
                if (isTutorial)
                {
#if BUILD_TYPE_DEBUG
                    Debug.LogError(string.Format("チュートリアルを表示する FLAG_TYPE:{0}", TutorialDialog.FLAG_TYPE.SCORE.ToString()));
#endif
                    TutorialDialog.Create().SetTutorialType(TutorialDialog.FLAG_TYPE.SCORE).Show(() =>
                    {
                        isTutorial = false;
                    });
                }

                m_HomeMenu.IsViewScoreInfo = false;
                m_ScoreDialog.Show(() =>
                {
                    m_ScoreDialog = null;
                    m_HomeMenu.IsViewScoreInfo = true;
                });
            }
            else
            {
                DestroyObject(m_ScoreDialog.gameObject);
                m_ScoreDialog = null;

                Dialog errorDialog = Dialog.Create(DialogType.DialogOK);
                errorDialog.SetDialogText(DialogTextType.Title, "警告");
                errorDialog.SetDialogText(DialogTextType.MainText, "スコアイベントは開催されていません。");
                errorDialog.SetDialogText(DialogTextType.OKText, "閉じる");
                errorDialog.SetDialogEvent(DialogButtonEventType.OK, () =>
                {
                    m_HomeMenu.IsViewScoreInfo = false;
                });
                errorDialog.Show();
            }
        })
        .setErrorAction((data) =>
        {
            DestroyObject(m_ScoreDialog.gameObject);
            m_ScoreDialog = null;
        })
        .SendStart();
    }
Exemplo n.º 9
0
    void OnClickTutorialDialog(OthersInfoListContext item)
    {
        SoundUtil.PlaySE(SEID.SE_MENU_OK2);

        TutorialDialog.Create().SetTutorialType(item.TutorialDialogType).DisableSaveShowFlag().Show();
    }
Exemplo n.º 10
0
    void OnShowDialog_ScratchInitial()
    {
        new SerialProcess().Add(
            (System.Action next) =>
        {
            TutorialDialog.Create().SetTutorialType(TutorialDialog.FLAG_TYPE.GACHA).Show(() =>
            {
                next();
            });
        }).Add(
            (System.Action next) =>
        {
            Dialog.Create(DialogType.DialogOK).
            SetTitleFromTextKey(("TUTORIAL_SCRATCH_RESULT01_TITLE").ToLower()).
            SetMainFromTextKey(("TUTORIAL_SCRATCH_RESULT01_MAIN").ToLower()).
            SetOkEvent(
                () =>
            {
                next();
            }).Show();
        }).Add(
            (System.Action next) =>
        {
            Dialog.Create(DialogType.DialogOK).
            SetTitleFromTextKey(("TUTORIAL_SCRATCH_RESULT02_TITLE").ToLower()).
            SetMainFromTextKey(("TUTORIAL_SCRATCH_RESULT02_MAIN").ToLower()).
            SetOkEvent(
                () =>
            {
                next();
            }).Show();
        })
        .Add(next =>
        {
            ServerDataUtilSend.SendPacketAPI_UserAuthentication().
            setSuccessAction(_data =>
            {
                next();
            }).
            setErrorAction(_data =>
            {
                //authError(_data.m_PacketCode, _data.m_PacketUniqueNum);
                next();
            }).
            SendStart();
        })
        .Add(
            (System.Action next) =>
        {
            InputLock(true);
            TutorialManager.SendStep(
                601,
                () =>
            {
                InputLock(false);
                TutorialFSM.Instance.SendFsmNextEvent();

                next();
            });
        }).Flush();
    }