|
@@ -1,5 +1,6 @@
|
|
|
using System.Collections;
|
|
|
using System.Collections.Generic;
|
|
|
+using System.IO;
|
|
|
|
|
|
namespace YooAsset.Editor
|
|
|
{
|
|
@@ -70,8 +71,12 @@ namespace YooAsset.Editor
|
|
|
int fileTotalCount = buildMapContext.Collection.Count;
|
|
|
foreach (var bundleInfo in buildMapContext.Collection)
|
|
|
{
|
|
|
- EditorTools.CopyFile(bundleInfo.BundleInfo.BuildOutputFilePath, bundleInfo.BundleInfo.PackageOutputFilePath, true);
|
|
|
- EditorTools.DisplayProgressBar("拷贝补丁文件", ++progressValue, fileTotalCount);
|
|
|
+ //判断文件已存在不更新,因为文件名中有hash值,可以保证文件最新
|
|
|
+ if(!File.Exists(bundleInfo.BundleInfo.PackageOutputFilePath))
|
|
|
+ {
|
|
|
+ EditorTools.CopyFile(bundleInfo.BundleInfo.BuildOutputFilePath, bundleInfo.BundleInfo.PackageOutputFilePath, true);
|
|
|
+ EditorTools.DisplayProgressBar("拷贝补丁文件", ++progressValue, fileTotalCount);
|
|
|
+ }
|
|
|
}
|
|
|
EditorTools.ClearProgressBar();
|
|
|
}
|