From c22cf5ffebdf0bedac1dc9a99c74d87c431a2107 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E4=BD=95=E5=86=A0=E5=B3=B0?= Date: Wed, 27 Aug 2025 16:04:18 +0800 Subject: [PATCH] fix #620 --- .../DownloadSystem/DownloadSystemHelper.cs | 15 ++++++++++----- 1 file changed, 10 insertions(+), 5 deletions(-) diff --git a/Assets/YooAsset/Runtime/DownloadSystem/DownloadSystemHelper.cs b/Assets/YooAsset/Runtime/DownloadSystem/DownloadSystemHelper.cs index dcc50e99..09ccd358 100644 --- a/Assets/YooAsset/Runtime/DownloadSystem/DownloadSystemHelper.cs +++ b/Assets/YooAsset/Runtime/DownloadSystem/DownloadSystemHelper.cs @@ -43,11 +43,11 @@ namespace YooAsset // 说明:AppleTV对应的是tvOS系统。 #if UNITY_EDITOR_OSX url = StringUtility.Format("file://{0}", path); -#elif UNITY_EDITOR +#elif UNITY_EDITOR_WIN url = StringUtility.Format("file:///{0}", path); #elif UNITY_WEBGL url = path; -#elif UNITY_IPHONE +#elif UNITY_IOS || UNITY_IPHONE url = StringUtility.Format("file://{0}", path); #elif UNITY_ANDROID if (path.StartsWith("jar:file://")) @@ -69,12 +69,17 @@ namespace YooAsset else url = StringUtility.Format("file://{0}", path); } -#elif UNITY_STANDALONE_OSX - url = new System.Uri(path).ToString(); -#elif UNITY_STANDALONE || UNITY_WSA + +#elif UNITY_WSA url = StringUtility.Format("file:///{0}", path); #elif UNITY_TVOS url = StringUtility.Format("file:///{0}", path); +#elif UNITY_STANDALONE_OSX + url = new System.Uri(path).ToString(); +#elif UNITY_STANDALONE_WIN + url = StringUtility.Format("file:///{0}", path); +#elif UNITY_STANDALONE_LINUX + url = StringUtility.Format("file:///root/{0}", path); #else throw new System.NotImplementedException(); #endif