Update PatchManifest
资源补丁清单增加文件版本信息
This commit is contained in:
@@ -12,6 +12,11 @@ namespace YooAsset
|
||||
[Serializable]
|
||||
internal class PatchManifest
|
||||
{
|
||||
/// <summary>
|
||||
/// 文件版本
|
||||
/// </summary>
|
||||
public string FileVersion;
|
||||
|
||||
/// <summary>
|
||||
/// 资源版本号
|
||||
/// </summary>
|
||||
@@ -229,6 +234,10 @@ namespace YooAsset
|
||||
{
|
||||
PatchManifest patchManifest = JsonUtility.FromJson<PatchManifest>(jsonData);
|
||||
|
||||
// 检测文件版本
|
||||
if (patchManifest.FileVersion != YooAssetSettings.PatchManifestFileVersion)
|
||||
throw new Exception($"The manifest file version are not compatible : {patchManifest.FileVersion} != {YooAssetSettings.PatchManifestFileVersion}");
|
||||
|
||||
// BundleList
|
||||
foreach (var patchBundle in patchManifest.BundleList)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user