internal AssetBase(string path, Type type, BundleLoaderBase target, BundlerContext context) { _loader = target; _path = path; _type = type; _context = context; ThrowIfBundleError(); LoadAsset(); }
internal LoadRequest(ModeBase mode, BundlerContext context, string path, BundleLoaderBase bundleLoader) { _path = path; _context = context; _mode = mode; _bundleLoader = bundleLoader; IsDone = _bundleLoader == null; if (!IsDone) { LoadInternal(); } }
internal SceneBase(string path, LoadSceneMode mode, BundlerContext context, BundleLoaderBase bundleLoader = null) { _path = path; _mode = mode; Context = context; _bundleLoader = bundleLoader; _scenePath = _path.Substring(7, _path.Length - 13); // Cut from "Assets/_____.unity" if (_bundleLoader != null && !_bundleLoader.IsDone) { throw new BundleException("Loader hasn't finished!"); } LoadInternal(); Retain(); }
private void LoadRecursive(BundleLoaderBase bundleLoader) { // Load dependencies at first foreach (var dependency in bundleLoader.Dependencies) { LoadRecursive(dependency); } // Load target at last if (!bundleLoader.IsStarted) { bundleLoader.Load(); } // Force load complete immediately if target is async loader. var async = bundleLoader as BundleLoaderAsync; if (async != null && !async.IsDone) { async.ForceLoadComplete(); } }
internal LoadRequestSync(ModeBase mode, BundlerContext context, string path, BundleLoaderBase bundleLoader) : base(mode, context, path, bundleLoader) { }
internal SceneAsync(string path, LoadSceneMode mode, BundlerContext context, BundleLoaderBase loader) : base(path, mode, context, loader) { }
internal BundleAssetAsync(string path, Type type, BundleLoaderBase target, BundlerContext context) : base(path, type, target, context) { }