update space shooter

mlyDevMerge1.5.7
hevinci 2023-06-16 14:10:33 +08:00 committed by QiJing
parent db81ba8d67
commit 0744d684e8
1 changed files with 8 additions and 0 deletions

View File

@ -23,6 +23,13 @@ public sealed class StreamingAssetsHelper
private static bool _isInit = false; private static bool _isInit = false;
private static readonly HashSet<string> _cacheData = new HashSet<string>(); private static readonly HashSet<string> _cacheData = new HashSet<string>();
#if UNITY_EDITOR
public static void Init() { _isInit = true; }
public static bool FileExists(string fileName)
{
return File.Exists(System.IO.Path.Combine(Application.streamingAssetsPath, "BuildinFiles", fileName));
}
#else
/// <summary> /// <summary>
/// 初始化 /// 初始化
/// </summary> /// </summary>
@ -49,6 +56,7 @@ public sealed class StreamingAssetsHelper
return _cacheData.Contains(fileName); return _cacheData.Contains(fileName);
} }
#endif
} }
#if UNITY_EDITOR #if UNITY_EDITOR