Example #1
0
    private void Init()
    {
        // 初始化服务模块
        NetSev.Instance.InitSev();
        ResSev.Instance.InitSev();
        AudioSev.Instance.InitSev();
        TimerSev.Instance.InitSev();
        TimerSev.Instance.StartTimer();

        // 初始化业务系统
        XLuaSys.InitSingleton().InitSys();
        CoroutineSys cor = CoroutineSys.InitSingleton();

        cor.InitSys();
        LoginSys login = LoginSys.InitSingleton();

        login.InitSys();
        MainCitySys mainCity = MainCitySys.InitSingleton();

        mainCity.InitSys();
        MissionSys missionSys = MissionSys.InitSingleton();

        missionSys.InitSys();
        BattleSys battleSys = BattleSys.InitSingleton();

        battleSys.InitSys();

        dynamicWindow.SetWindowState(true);
        // 进入登录场景并加载相应UI
        login.EnterLogin();

        //AddTips("Tips1");
        //AddTips("Tips2");
    }
Example #2
0
    void ClearUI()
    {
        Transform canvas = transform.Find("Canvas");

        for (int i = 0; i < canvas.childCount; i++)
        {
            canvas.GetChild(i).gameObject.SetActive(false);
        }
        dynamicWindow.SetWindowState(true);
    }
Example #3
0
    public void InitUI()
    {
        Transform canvas    = transform.Find("Canvas");
        Transform uiWindows = canvas.Find("UIWindows");

        for (int i = 0; i < uiWindows.childCount; i++)
        {
            uiWindows.GetChild(i).gameObject.SetActive(false);
        }

        dynamicWindow.SetWindowState(true);
    }