Exemple #1
0
        public void Run()
        {
            if (_loadingFilter.IsEmpty())
            {
                return;
            }

            foreach (var idx in _loadingFilter)
            {
                var activeLoading = _loadingFilter.Get1(idx);

                if (!_IsEverySceneLoaded(activeLoading.Progresses))
                {
                    continue;
                }

                _ProcessScenes(activeLoading.Progresses);

                if (activeLoading.UnloadOthers)
                {
                    World.UnloadNonNewScenes();
                }
                else if (activeLoading.UnloadScenes != null)
                {
                    World.UnloadScenes(activeLoading.UnloadScenes);
                }

                _loadingFilter.GetEntity(idx).Get <RemoveEntityComponent>();
            }
        }