示例#1
0
        private void InitApp()
        {
            SetGameConfig();
#if UNITY_EDITOR
            //DebugMgr.Instance.Init();         //Debug工具初始化;
#endif
            EventMgr.Instance.OnInitialize();     //事件系统初始化;
            UIEventMgr <int> .Init();             //UI事件系统初始化;

            SdkMgr.Instance.OnInitialize();       //平台初始化;
            TimerMgr.Instance.OnInitialize();     //定时器初始化;
            ComponentMgr.Instance.OnInitialize(); //组件初始化;
            EntityMgr.Instance.OnInitialize();    //实体初始化;
            UIMgr.Instance.OnInitialize();        //UI初始化;
            SceneMgr.Instance.OnInitialize();     //场景初始化;
            LuaMgr.Instance.OnInitialize();       //lua初始化;
            MemoryMgr.Instance.OnInitialize();
            NetMgr.Instance.OnInitialize();       //网络初始化;
        }
示例#2
0
        void OnGUI()
        {
            if (GUI.Button(new Rect(10, 10, 200, 50), "Event1 Fire"))
            {
                UIEventMgr <EventTestEnum> .FireEvent(EventTestEnum.TestEnum);
            }
            if (GUI.Button(new Rect(10, 70, 200, 50), "Event1 Remove"))
            {
                UIEventMgr <EventTestEnum> .RemoveEvent(EventTestEnum.TestEnum, OnEvent1);
            }

            if (GUI.Button(new Rect(10, 130, 200, 50), "Event2 Fire"))
            {
                UIEventMgr <EventTestEnum> .FireEvent <int>(EventTestEnum.TestEnum, 12345);
            }
            if (GUI.Button(new Rect(10, 200, 200, 50), "Event2 Remove"))
            {
                UIEventMgr <EventTestEnum> .RemoveEvent <int>(EventTestEnum.TestEnum, OnEvent2);
            }
        }
示例#3
0
        private void InitApp()
        {
            PoolMgr.Instance.ClearFinishHandler = null;
            SetGameConfig();
#if UNITY_EDITOR
            DebugMgr.Instance.InitMgr();         //Debug工具初始化;
#endif
            EventMgr.Instance.InitMgr();         //事件系统初始化;
            UIEventMgr <int> .InitMgr();         //UI事件系统初始化;

            SdkMgr.Instance.InitMgr();           //平台初始化;
            TimerMgr.Instance.InitMgr();         //定时器初始化;
            ComponentMgr.Instance.InitMgr();     //组件初始化;
            EntityMgr.Instance.InitMgr();        //实体初始化;
            ResourceMgr.Instance.InitMgr();      //资源初始化;
            UIMgr.Instance.InitMgr();            //UI初始化;
            SceneMgr.Instance.InitMgr();         //场景初始化;
            LuaMgr.Instance.InitMgr();           //lua初始化;
            NetMgr.Instance.InitMgr();           //网络初始化;
            MemoryMgr.Instance.InitMgr();
        }
示例#4
0
        void Start()
        {
            UIEventMgr <EventTestEnum> .AddEvent(EventTestEnum.TestEnum, OnEvent1);

            UIEventMgr <EventTestEnum> .AddEvent <int>(EventTestEnum.TestEnum, OnEvent2);
        }