2021-04-20 00:25:04 +08:00
|
|
|
|
#if UNITY
|
|
|
|
|
|
|
|
|
|
using UnityEngine;
|
2021-04-08 20:09:59 +08:00
|
|
|
|
|
|
|
|
|
namespace ET
|
|
|
|
|
{
|
|
|
|
|
public static class PathHelper
|
|
|
|
|
{ /// <summary>
|
|
|
|
|
///应用程序外部资源路径存放路径(热更新资源路径)
|
|
|
|
|
/// </summary>
|
|
|
|
|
public static string AppHotfixResPath
|
|
|
|
|
{
|
|
|
|
|
get
|
|
|
|
|
{
|
|
|
|
|
string game = Application.productName;
|
|
|
|
|
string path = AppResPath;
|
|
|
|
|
if (Application.isMobilePlatform)
|
|
|
|
|
{
|
|
|
|
|
path = $"{Application.persistentDataPath}/{game}/";
|
|
|
|
|
}
|
|
|
|
|
return path;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// 应用程序内部资源路径存放路径
|
|
|
|
|
/// </summary>
|
|
|
|
|
public static string AppResPath
|
|
|
|
|
{
|
|
|
|
|
get
|
|
|
|
|
{
|
|
|
|
|
return Application.streamingAssetsPath;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// 应用程序内部资源路径存放路径(www/webrequest专用)
|
|
|
|
|
/// </summary>
|
|
|
|
|
public static string AppResPath4Web
|
|
|
|
|
{
|
|
|
|
|
get
|
|
|
|
|
{
|
|
|
|
|
#if UNITY_IOS || UNITY_STANDALONE_OSX
|
|
|
|
|
return $"file://{Application.streamingAssetsPath}";
|
|
|
|
|
#else
|
|
|
|
|
return Application.streamingAssetsPath;
|
|
|
|
|
#endif
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
public const string HotfixDll = "Assets/Download/Config/Hotfix.dll.bytes";
|
|
|
|
|
public const string HotfixPdb = "Assets/Download/Config/Hotfix.pdb.bytes";
|
|
|
|
|
public const string HotfixViewDll = "Assets/Download/Config/HotfixView.dll.bytes";
|
|
|
|
|
public const string HotfixViewPdb = "Assets/Download/Config/HotfixView.pdb.bytes";
|
|
|
|
|
public const string FUIABFormat = "download/fgui/{0}.assetbundle";
|
|
|
|
|
public const string FUIAB = "download/fgui.assetbundle";
|
|
|
|
|
}
|
|
|
|
|
}
|
2021-04-20 00:25:04 +08:00
|
|
|
|
|
|
|
|
|
#endif
|