fix:1、修复bug
This commit is contained in:
@@ -20,8 +20,8 @@ namespace FGUI.LG_live
|
||||
{
|
||||
base.ConstructFromXML(xml);
|
||||
|
||||
list_ = (GList)GetChildAt(1);
|
||||
btn_close = (GButton)GetChildAt(2);
|
||||
list_ = (GList)GetChildAt(2);
|
||||
btn_close = (GButton)GetChildAt(3);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -25,9 +25,9 @@ namespace FGUI.ZM_Pass_14
|
||||
|
||||
type = GetControllerAt(0);
|
||||
state = GetControllerAt(1);
|
||||
item_loader = (GLoader)GetChildAt(3);
|
||||
number_text = (GTextField)GetChildAt(4);
|
||||
btn_claim = (GButton)GetChildAt(5);
|
||||
item_loader = (GLoader)GetChildAt(2);
|
||||
number_text = (GTextField)GetChildAt(3);
|
||||
btn_claim = (GButton)GetChildAt(4);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -216,27 +216,27 @@ public class TextureHelper
|
||||
public static string getResPath()
|
||||
{
|
||||
// 删除旧资源
|
||||
if (!DataMgr.curResVersion.Value.IsNullOrWhiteSpace() && DataMgr.curResVersion.Value != ConfigSystem.GetCommonConf().ResVersion)
|
||||
if (!DataMgr.curResVersion.Value.IsNullOrWhiteSpace() && DataMgr.curResVersion.Value != ConfigSystem.GetConfigResVersion())
|
||||
{
|
||||
var oldFolder = Path.Combine(Application.persistentDataPath, DataMgr.curResVersion.Value);
|
||||
if (Directory.Exists(oldFolder))
|
||||
{
|
||||
Directory.Delete(oldFolder, true);
|
||||
}
|
||||
DataMgr.curResVersion.Value = ConfigSystem.GetCommonConf().ResVersion;
|
||||
DataMgr.curResVersion.Value = ConfigSystem.GetConfigResVersion();
|
||||
}
|
||||
else if (DataMgr.curResVersion.Value.IsNullOrWhiteSpace())
|
||||
{
|
||||
DataMgr.curResVersion.Value = ConfigSystem.GetCommonConf().ResVersion;
|
||||
DataMgr.curResVersion.Value = ConfigSystem.GetConfigResVersion();
|
||||
}
|
||||
|
||||
if (ConfigSystem.GetCommonConf().ResVersion.IsNullOrWhiteSpace())
|
||||
if (ConfigSystem.GetConfigResVersion().IsNullOrWhiteSpace())
|
||||
{
|
||||
Debug.LogError("获取资源路径失败");
|
||||
return Application.persistentDataPath;
|
||||
}
|
||||
|
||||
string curFolder = Path.Combine(Application.persistentDataPath, ConfigSystem.GetCommonConf().ResVersion);
|
||||
string curFolder = Path.Combine(Application.persistentDataPath, ConfigSystem.GetConfigResVersion());
|
||||
return curFolder;
|
||||
}
|
||||
|
||||
@@ -246,7 +246,7 @@ public class TextureHelper
|
||||
var localPath = Path.Combine(getResPath(), localFolder, fileName + ".jpg");
|
||||
if (File.Exists(localPath))
|
||||
{
|
||||
Debug.Log($"[SetImgLoader] 本地存在,直接加载 {fileName}");
|
||||
Debug.Log($"[SetImgLoader] 本地存在,直接加载 {fileName} localPath:{localPath}");
|
||||
CrazyAsyKit.StartCoroutine(LoadTexture(fileName, loader, callback, localFolder, isGameBg));
|
||||
return;
|
||||
}
|
||||
@@ -512,6 +512,7 @@ public static IEnumerator LoadTexture(string fileName, GLoader loader, Action<NT
|
||||
|
||||
if (loader != null) loaderRequests.Remove(loader);
|
||||
|
||||
Debug.Log($"[LoadTexture www] www.result {www.result}");
|
||||
if (www.result == UnityWebRequest.Result.Success)
|
||||
{
|
||||
var tex = DownloadHandlerTexture.GetContent(www);
|
||||
@@ -559,7 +560,7 @@ public static IEnumerator LoadTexture(string fileName, GLoader loader, Action<NT
|
||||
public static string GetDecryptedImagePath(string fileName, string localFolder)
|
||||
{
|
||||
string tempPath = Path.Combine(Application.temporaryCachePath, FolderNames.GameCache, localFolder, fileName + "_temp.jpg");
|
||||
// Debug.Log($"获取解密路径: {tempPath}");
|
||||
Debug.Log($"获取解密路径: {tempPath}");
|
||||
|
||||
if (!File.Exists(tempPath))
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user