Ejemplo n.º 1
0
        private new void Awake()
        {
            base.Awake();
            mEngineLoop = new EngineLoop(this);
            PreloadManager.GetOrAlloc();

            DebugUtility.Log(LoggerTags.Engine, "EngineLoop Start Frame : {0}", Time.frameCount);
            //DebugUtility.Log(LoggerTags.Engine, "EngineLoop End Frame : {0}", Time.frameCount);
        }
Ejemplo n.º 2
0
        private IEnumerator InitializeAsync(UEngine engine)
        {
            DebugUtility.Log(LoggerTags.Engine, "EngineLoop.InitializeAsync: {0}", Time.realtimeSinceStartup);
            if (!initialized)
            {
                // Initialize the preload manager
                yield return(engine.StartCoroutine(PreloadManager.GetOrAlloc().Initialize()));

                // apply engine settings
                var engineConfig = EngineSettings.GetOrLoad();
                if (engineConfig != null)
                {
                    DebugUtility.Initialize(engineConfig.loggerSettings);
                }
                // Initialize the modules
                yield return(engine.StartCoroutine(ModuleManager.Get().OnModuleInitialize(engine)));

                initialized = true;
            }

            DebugUtility.Log(LoggerTags.Engine, "EngineLoop.InitializeAsync done: {0}", Time.realtimeSinceStartup);
        }