public void Init(IDownloadable downloadable, DownloadProgressObserver observer)
 {
     this.fileName        = downloadable.GetBundleName();
     this.serverUrl       = downloadable.GetServerUrl();
     this.observer        = observer;
     this.loadOnComplete  = downloadable.IsLoadOnComplete();
     this.downloadVersion = downloadable.GetVersion();
     this.priority        = downloadable.GetPriority();
 }
Example #2
0
    public Texture2D GetAssetBundle(IDownloadable downloadable)
    {
        string bundleName = downloadable.GetBundleName();

        if (downloadable.IsLoadOnComplete() && imageAssets.ContainsKey(bundleName))
        {
            return(imageAssets [bundleName]);
        }
        else
        {
            baseDownloadManager.LoadBundle(downloadable);
        }
        return(null);
    }