Beispiel #1
0
    private static void DestroyFrameWorkEvent(int lv)
    {
        if (Schedule.mIns != null)
        {
            Schedule.mIns.Destroy();
        }

        if (GameSceneCtr.mIns != null)
        {
            GameSceneCtr.mIns.Destroy();
        }

        if (GameUIControl.mIns != null)
        {
            GameUIControl.mIns.Destroy();
        }


        if (KObjectPool.mIns != null)
        {
            KObjectPool.mIns.Clear();
        }

        if (GameSyncCtr.mIns != null)
        {
            GameSyncCtr.mIns.EndSync();
        }


        FrameCommand.Destroy();
        WaitTaskCommand.Destroy();
        TimeCommand.Destroy();

        FrameworkAttRegister.DestroyAttEvent(MainLoopEvent.Start, typeof(WaitTaskCommand), "PreLoad");
        FrameworkAttRegister.DestroyAttEvent(MainLoopEvent.Start, typeof(TimeCommand), "PreLoad");
        FrameworkAttRegister.DestroyAttEvent(MainLoopEvent.Start, typeof(FrameCommand), "PreLoad");
        FrameworkAttRegister.DestroyAttEvent(MainLoopEvent.Start, typeof(BundlePathConvert), "PreLoad");
        FrameworkAttRegister.DestroyAttEvent(MainLoopEvent.Start, typeof(GenericParams), "Preload");
        FrameworkAttRegister.DestroyAttEvent(MainLoopEvent.Start, typeof(SimpleParams), "Preload");
        FrameworkAttRegister.DestroyAttEvent(MainLoopEvent.OnDestroy, typeof(FrameWorkConfig), "DestroyFrameWorkEvent");
    }
Beispiel #2
0
    public static void Register(FrameworkAttRegister frameWork)
    {
        frameWork.RegisterHandler(RegisterType.ClassAttr, typeof(SingleTonAttribute), Register_Singleton);
        frameWork.RegisterHandler(RegisterType.MethodAtt, typeof(SceneEnterAttribute), Register_SceneAtt);
        frameWork.RegisterHandler(RegisterType.MethodAtt, typeof(SceneLeaveAttribute), Register_SceneLeaveAtt);
        frameWork.RegisterHandler(RegisterType.MethodAtt, typeof(Script_SharpLogicAttribute), Register_SharpScriptLogicAtt);
        frameWork.RegisterHandler(RegisterType.MethodAtt, typeof(Script_LuaLogicAttribute), Register_LuaScriptLogicAtt);
        frameWork.RegisterHandler(RegisterType.MethodAtt, typeof(FrameWorkDestroyAttribute), Register_KFKDestroyAtt);
        frameWork.RegisterHandler(RegisterType.MethodAtt, typeof(FrameWorkStartAttribute), Register_KFKStartcAtt);
        frameWork.RegisterHandler(RegisterType.MethodAtt, typeof(FrameWorkDevicePausedAttribute), Register_KFKPauseAtt);
        frameWork.RegisterHandler(RegisterType.MethodAtt, typeof(FrameWorkDeviceQuitAttribute), Register_KFKQuitAtt);
        frameWork.RegisterHandler(RegisterType.MethodAtt, typeof(FrameWorkDisableAttribute), Register_KFKDisableAtt);
        frameWork.RegisterHandler(RegisterType.MethodAtt, typeof(FrameWorkEnableAttribute), Register_KFKEnableAtt);
        frameWork.RegisterHandler(RegisterType.MethodAtt, typeof(FrameWorkFixedUpdateAttribute), Register_KFKFixedupdateAtt);
        frameWork.RegisterHandler(RegisterType.MethodAtt, typeof(FrameWorkUpdateAttribute), Register_KFKUpdateAtt);
        frameWork.RegisterHandler(RegisterType.MethodAtt, typeof(FrameWorkLateUpdateAttribute), Register_KFKLateupdateAtt);
        frameWork.RegisterHandler(RegisterType.MethodAtt, typeof(FrameWorkBeforeUpdateAttribute), Register_KFKBeforeUpdateAtt);
        frameWork.RegisterHandler(RegisterType.MethodAtt, typeof(FrameWorkAfterUpdateAttribute), Register_KFKAfterUpdateAtt);
        frameWork.RegisterHandler(RegisterType.MethodAtt, typeof(DelegateMethodAttribute), Register_DelegateAtt);

        frameWork.RegisterHandler(RegisterType.Register, typeof(ModelRegisterAttribute), Reigister_Model);
        //GameAttrRegister.Register(frameWork);
    }