public void unregisterUIDialogManager(NvUIDialogManager mgr)
 {
     if (mgr != null)
     {
         if (m_dlgManagerChain.ContainsKey(mgr.gameObject.name))
         {
             m_dlgManagerChain.Remove(mgr.gameObject.name);
         }
     }
 }
 public void registerUIDialogManager(NvUIDialogManager mgr)
 {
     if (mgr != null && mgr.gameObject.name != "")
     {
         string mgrName = mgr.gameObject.name;
         if (m_dlgManagerChain.ContainsKey(mgrName) == false)
         {
             m_dlgManagerChain.Add(mgrName, mgr);
         }
     }
 }
    void AddUIDancingMainEnd(string str)
    {
        GameObject obj = GameObject.Find("DancingMain");

        if (obj)
        {
            NvUIDialogManager m_DialogMgr = obj.GetComponent(typeof(NvUIDialogManager)) as NvUIDialogManager;
            DcDancingMainDlg  dlgDM       = m_DialogMgr.FindDialog("DancingMainDlg") as DcDancingMainDlg;
            obj = GameObject.Find("CharManager");
            dlgDM.InitCharMgr(obj.GetComponent <DcCharMgr>());
            dlgDM.StartDancing();
        }
    }
    IEnumerator _CreateDlg()
    {
        GameObject obj = GameObject.Find(strUIRoot);

        while (!obj)
        {
            yield return(new WaitForSeconds(0.1f));

            obj = GameObject.Find(strUIRoot);
        }

        NvUIDialogManager m_DialogMgr = obj.GetComponent(typeof(NvUIDialogManager)) as NvUIDialogManager;

        m_DialogMgr.OpenDialog(strDlgName);
    }
    void AddChallengeListEnd(string str)
    {
        GameObject obj = GameObject.Find("ChallengeList");

        if (obj)
        {
            //Debug.Log("AddChallengeListEnd Succeed");
            NvUIDialogManager  m_DialogMgr = obj.GetComponent(typeof(NvUIDialogManager)) as NvUIDialogManager;
            DcChallengeListDlg dlgCL       = m_DialogMgr.FindDialog("ChallengeListDlg") as DcChallengeListDlg;
            dlgCL.SetChallengeChallenge();
            dlgCL.InitChbSel();
            //Debug.Log("dlgCL.nCurSelScene:" + dlgCL.nCurSelScene);
        }
        else
        {
            Debug.Log("AddChallengeListEnd Fail");
        }
    }
Beispiel #6
0
    void OnClick()
    {
        GameObject obj = GameObject.Find("Interior");

        if (obj)
        {
            NvUIDialogManager m_DialogMgr = obj.GetComponent(typeof(NvUIDialogManager)) as NvUIDialogManager;
            DcInteriorDlg     dlgI        = m_DialogMgr.FindDialog("InteriorDlg") as DcInteriorDlg;
            if (dlgI.gameObject.active)
            {
                dlgI.GotoPersonal();
            }
        }

        obj = GameObject.Find("CreateCharacter");
        if (obj)
        {
        }
    }