From 3b1a8beadf21b4856edac3a1179014b070a94c1b Mon Sep 17 00:00:00 2001 From: hevinci Date: Wed, 21 Dec 2022 17:10:28 +0800 Subject: [PATCH] update runtime code --- Assets/YooAsset/Runtime/Settings/YooAssetSettings.cs | 1 + Assets/YooAsset/Runtime/Settings/YooAssetSettingsData.cs | 9 +++++++-- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/Assets/YooAsset/Runtime/Settings/YooAssetSettings.cs b/Assets/YooAsset/Runtime/Settings/YooAssetSettings.cs index bee373a..237f1d0 100644 --- a/Assets/YooAsset/Runtime/Settings/YooAssetSettings.cs +++ b/Assets/YooAsset/Runtime/Settings/YooAssetSettings.cs @@ -41,6 +41,7 @@ namespace YooAsset /// public const string PatchManifestFileVersion = "1.4.0"; + /// /// 构建输出文件夹名称 /// diff --git a/Assets/YooAsset/Runtime/Settings/YooAssetSettingsData.cs b/Assets/YooAsset/Runtime/Settings/YooAssetSettingsData.cs index 7a38d1d..056c5c7 100644 --- a/Assets/YooAsset/Runtime/Settings/YooAssetSettingsData.cs +++ b/Assets/YooAsset/Runtime/Settings/YooAssetSettingsData.cs @@ -83,9 +83,14 @@ namespace YooAsset /// /// 获取着色器资源包全名称(包含后缀名) /// - public static string GetUnityShadersBundleFullName() + public static string GetUnityShadersBundleFullName(bool uniqueBundleName, string packageName) { - return $"{YooAssetSettings.UnityShadersBundleName}.{Setting.AssetBundleFileVariant}"; + string shareBundleName; + if (uniqueBundleName) + shareBundleName = $"{packageName.ToLower()}_{YooAssetSettings.UnityShadersBundleName}.{Setting.AssetBundleFileVariant}"; + else + shareBundleName = $"{YooAssetSettings.UnityShadersBundleName}.{Setting.AssetBundleFileVariant}"; + return shareBundleName.ToLower(); } } } \ No newline at end of file