コード例 #1
0
ファイル: Library.cs プロジェクト: Northcode/MCM-reboot
 public void ScheduleExtract(DownloadPackage pkg)
 {
     if (!File.Exists(Extractpath))
     {
         Download dl = pkg.ScheduleDownload(this.Name,this.Url);
         ApplyDlStuff(dl);
     }
 }
コード例 #2
0
 public void ScheduleExtract(DownloadPackage pkg)
 {
     if (!File.Exists(Extractpath))
     {
         Download dl = pkg.ScheduleDownload(this.Name, this.Url);
         ApplyDlStuff(dl);
     }
 }
コード例 #3
0
        internal static void ScheduleAssetDownloads()
        {
            bool                  need   = false;
            DownloadPackage       dlp    = new DownloadPackage("Assets", true);
            List <MinecraftAsset> needDl = new List <MinecraftAsset>();

            assets.ForEach(a => {
                if (a.NeedsDownload())
                {
                    needDl.Add(a);
                    Download dl    = dlp.ScheduleDownload(a.Key, a.Url);
                    dl.Downloaded += AssetDownloaded;
                    need           = true;
                }
            });
            if (need)
            {
                DownloadManager.ScheduleDownload(dlp);
            }
        }
コード例 #4
0
 internal static void ScheduleAssetDownloads()
 {
     bool need = false;
     DownloadPackage dlp = new DownloadPackage("Assets", true);
     List<MinecraftAsset> needDl = new List<MinecraftAsset>();
     assets.ForEach(a => {
         if (a.NeedsDownload())
         {
             needDl.Add(a);
             Download dl = dlp.ScheduleDownload(a.Key, a.Url);
             dl.Downloaded += AssetDownloaded;
             need = true;
         }
     });
     if(need)
         DownloadManager.ScheduleDownload(dlp);
 }