少年修仙传客户端代码仓库
hch
2023-06-15 7c4696c93e297a78cbad4cdc3b58c2329f38ed5f
0312 版本同步-语言增加默认为空的选项
5个文件已修改
25 ■■■■■ 已修改文件
Core/GameEngine/Login/LoginStage.cs 2 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
System/AssetVersion/AssetVersionUtility.cs 2 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
System/AssetVersion/DownLoadAndDiscompressTask.cs 2 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
System/AssetVersion/InGameDownLoad.cs 2 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
System/Language/Language.cs 17 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Core/GameEngine/Login/LoginStage.cs
@@ -126,7 +126,7 @@
            if (check && VersionUtility.Instance.NeedDownAsset())
            {
                checkAssetVersionTimer += Time.time + 10f;
                var assetVersionUrl = StringUtility.Contact(VersionUtility.Instance.versionInfo.GetResourcesURL(VersionConfig.Get().branch), "/", Language.Id, "/AssetsVersion.txt");
                var assetVersionUrl = StringUtility.Contact(VersionUtility.Instance.versionInfo.GetResourcesURL(VersionConfig.Get().branch), Language.fixPath, "/AssetsVersion.txt");
                HttpRequest.Instance.RequestHttpGet(assetVersionUrl, HttpRequest.defaultHttpContentType, 3, OnGetAssetVersionFile);
            }
        }
System/AssetVersion/AssetVersionUtility.cs
@@ -66,7 +66,7 @@
    {
        checkAssetCompleted = false;
        Debug.LogFormat("开始获取资源版本文件:时间 {0}", DateTime.Now);
        var assetVersionUrl = StringUtility.Contact(VersionUtility.Instance.versionInfo.GetResourcesURL(VersionConfig.Get().branch), "/", Language.Id, "/AssetsVersion.txt");
        var assetVersionUrl = StringUtility.Contact(VersionUtility.Instance.versionInfo.GetResourcesURL(VersionConfig.Get().branch), Language.fixPath, "/AssetsVersion.txt");
        assetVerUrl = assetVersionUrl;
        Debug.Log("http地址:assetVersionUrl  " + assetVersionUrl);
        HttpRequest.Instance.RequestHttpGet(assetVersionUrl, HttpRequest.defaultHttpContentType, 3, OnGetAssetVersionFile);
System/AssetVersion/DownLoadAndDiscompressTask.cs
@@ -99,7 +99,7 @@
            for (int i = 0; i < tasks.Count; i++)
            {
                var assetVersion = tasks[i];
                var remoteURL = StringUtility.Contact(VersionUtility.Instance.versionInfo.GetResourcesURL(VersionConfig.Get().branch), "/", Language.Id, "/", assetVersion.relativePath);
                var remoteURL = StringUtility.Contact(VersionUtility.Instance.versionInfo.GetResourcesURL(VersionConfig.Get().branch), Language.fixPath, "/", assetVersion.relativePath);
                var localURL = StringUtility.Contact(ResourcesPath.Instance.ExternalStorePath, assetVersion.relativePath);
                DownloadMgr.Instance.AddTask(new DownloadTask(remoteURL, localURL));
            }
System/AssetVersion/InGameDownLoad.cs
@@ -163,7 +163,7 @@
                mapTasks[mapId].Add(assetVersion);
            }
            //添加下载任务
            var remoteURL = StringUtility.Contact(VersionUtility.Instance.versionInfo.GetResourcesURL(VersionConfig.Get().branch), "/", Language.Id, "/", assetVersion.relativePath);
            var remoteURL = StringUtility.Contact(VersionUtility.Instance.versionInfo.GetResourcesURL(VersionConfig.Get().branch), Language.fixPath, "/", assetVersion.relativePath);
            var localURL = StringUtility.Contact(ResourcesPath.Instance.ExternalStorePath, assetVersion.relativePath);
            DownloadMgr.Instance.AddTask(new DownloadTask(remoteURL, localURL, assetVersion));
        }
System/Language/Language.cs
@@ -37,7 +37,7 @@
        var config = InitialFunctionConfig.Get("Language").Numerical2;
        if (string.IsNullOrEmpty(config))
            return;
        var id = LocalSave.GetString("LANGUAGE_ID");
        var id = LocalSave.GetString("LANGUAGE_ID1");
        if (!string.IsNullOrEmpty(id))
            return;
        switch (Application.systemLanguage)
@@ -67,14 +67,25 @@
    {
        get
        {
            var id = LocalSave.GetString("LANGUAGE_ID");
            var id = LocalSave.GetString("LANGUAGE_ID1");
            if (string.IsNullOrEmpty(id))
                id = defaultId;
            return id;
        }
        set
        {
            LocalSave.SetString("LANGUAGE_ID", value);
            LocalSave.SetString("LANGUAGE_ID1", value);
        }
    }
    //默认路径不附加地址,Id不为空时附加Id
    public static string fixPath
    {
        get
        {
            if (string.IsNullOrEmpty(Id))
                return "";
            return string.Format("/{0}", Id);
        }
    }