| | |
| | | { |
| | | timer = 1f; |
| | | var seconds = Mathf.RoundToInt(m_ButtonEx.ableTime - Time.realtimeSinceStartup); |
| | | m_CoolDownText.text = StringUtility.Contact(seconds.ToString(), Language.Get("RealmWin_Bewrite_35")); |
| | | m_CoolDownText.text = StringUtility.Concat(seconds.ToString(), Language.Get("RealmWin_Bewrite_35")); |
| | | } |
| | | } |
| | | else |
| | |
| | | { |
| | | return dict[_type]; |
| | | } |
| | | var _cfg= BuiltInLoader.LoadScriptableObject<EnableButtonConfig>(StringUtility.Contact("EnableButton_", _type.ToString())); |
| | | var _cfg= BuiltInLoader.LoadScriptableObject<EnableButtonConfig>(StringUtility.Concat("EnableButton_", _type.ToString())); |
| | | dict.Add(_type, _cfg); |
| | | return _cfg; |
| | | } |
| | |
| | | protected override void UpdateTimeShow() |
| | | { |
| | | var lastSecond = (endTime - TimeUtility.ServerNow).TotalSeconds; |
| | | m_TimeShow.text = StringUtility.Contact(TimeUtility.SecondsToDHMSCHS((int)lastSecond), addtionInfo); |
| | | m_TimeShow.text = StringUtility.Concat(TimeUtility.SecondsToDHMSCHS((int)lastSecond), addtionInfo); |
| | | } |
| | | } |
| | | |
| | |
| | | |
| | | protected override void OnConfigParseCompleted() |
| | | { |
| | | m_ReplaceCfgs.Add(StringUtility.Contact(Identification, Number.ToString()), this); |
| | | m_ReplaceCfgs.Add(StringUtility.Concat(Identification, Number.ToString()), this); |
| | | } |
| | | |
| | | public static string GetRichReplace(string identify, int number) |
| | | { |
| | | RichTextMsgReplaceConfig replace = null; |
| | | m_ReplaceCfgs.TryGetValue(StringUtility.Contact(identify, number.ToString()), out replace); |
| | | m_ReplaceCfgs.TryGetValue(StringUtility.Concat(identify, number.ToString()), out replace); |
| | | if (replace != null) |
| | | { |
| | | return replace.Content; |
| | |
| | | for (int i = 1; i <= cfg.frameCnt; i++) |
| | | { |
| | | string spritePath = "Sprite/" + cfg.folder; |
| | | string spriteName = StringUtility.Contact(cfg.name, "_", i.ToString()); |
| | | string spriteName = StringUtility.Concat(cfg.name, "_", i.ToString()); |
| | | |
| | | Sprite sprite = ResManager.Instance.LoadAsset<Sprite>(spritePath, spriteName); |
| | | if (sprite != null) |
| | |
| | | |
| | | var fileNames = new List<string>(); |
| | | //var files = new List<FileInfo>(); |
| | | //FileExtersion.GetAllDirectoryFileInfos(StringUtility.Contact(ResourcesPath.Instance.StreamingAssetPath, "builtin"), files); |
| | | //FileExtersion.GetAllDirectoryFileInfos(StringUtility.Concat(ResourcesPath.Instance.StreamingAssetPath, "builtin"), files); |
| | | //foreach (var file in files) |
| | | //{ |
| | | // var name = Path.GetFileName(file.FullName); |
| | | // fileNames.Add(StringUtility.Contact("builtin", Path.DirectorySeparatorChar, name)); |
| | | // fileNames.Add(StringUtility.Concat("builtin", Path.DirectorySeparatorChar, name)); |
| | | //} |
| | | |
| | | //fileNames.Add("builtin_assetbundle"); |
| | | //fileNames.Add("builtin_assetbundle.manifest"); |
| | | |
| | | var configFiles = new List<FileInfo>(); |
| | | FileExtersion.GetAllDirectoryFileInfos(StringUtility.Contact(ResourcesPath.Instance.StreamingAssetPath, "config"), configFiles); |
| | | FileExtersion.GetAllDirectoryFileInfos(StringUtility.Concat(ResourcesPath.Instance.StreamingAssetPath, "config"), configFiles); |
| | | foreach (var file in configFiles) |
| | | { |
| | | var name = Path.GetFileName(file.FullName); |
| | | fileNames.Add(StringUtility.Contact("config", Path.DirectorySeparatorChar.ToString(), name)); |
| | | fileNames.Add(StringUtility.Concat("config", Path.DirectorySeparatorChar.ToString(), name)); |
| | | } |
| | | |
| | | foreach (var item in fileNames) |
| | | { |
| | | var fromPath = StringUtility.Contact(ResourcesPath.Instance.StreamingAssetPath, item); |
| | | var toPath = StringUtility.Contact(targetDirectory, item); |
| | | var fromPath = StringUtility.Concat(ResourcesPath.Instance.StreamingAssetPath, item); |
| | | var toPath = StringUtility.Concat(targetDirectory, item); |
| | | |
| | | var destDirectoryName = Path.GetDirectoryName(toPath); |
| | | if (!Directory.Exists(destDirectoryName)) |
| | |
| | | |
| | | var fileNames = new List<string>(); |
| | | //var files = new List<FileInfo>(); |
| | | //FileExtersion.GetAllDirectoryFileInfos(StringUtility.Contact(ResourcesPath.Instance.StreamingAssetPath, "builtin"), files); |
| | | //FileExtersion.GetAllDirectoryFileInfos(StringUtility.Concat(ResourcesPath.Instance.StreamingAssetPath, "builtin"), files); |
| | | //foreach (var file in files) |
| | | //{ |
| | | // var name = Path.GetFileName(file.FullName); |
| | | // fileNames.Add(StringUtility.Contact("builtin", Path.DirectorySeparatorChar, name)); |
| | | // fileNames.Add(StringUtility.Concat("builtin", Path.DirectorySeparatorChar, name)); |
| | | //} |
| | | |
| | | //fileNames.Add("builtin_assetbundle"); |
| | | //fileNames.Add("builtin_assetbundle.manifest"); |
| | | |
| | | var configFiles = new List<FileInfo>(); |
| | | FileExtersion.GetAllDirectoryFileInfos(StringUtility.Contact(ResourcesPath.Instance.StreamingAssetPath, "config"), configFiles); |
| | | FileExtersion.GetAllDirectoryFileInfos(StringUtility.Concat(ResourcesPath.Instance.StreamingAssetPath, "config"), configFiles); |
| | | foreach (var file in configFiles) |
| | | { |
| | | var name = Path.GetFileName(file.FullName); |
| | | fileNames.Add(StringUtility.Contact("config", Path.DirectorySeparatorChar.ToString(), name)); |
| | | fileNames.Add(StringUtility.Concat("config", Path.DirectorySeparatorChar.ToString(), name)); |
| | | } |
| | | |
| | | foreach (var item in fileNames) |
| | | { |
| | | var fromPath = StringUtility.Contact(ResourcesPath.Instance.StreamingAssetPath, item); |
| | | var toPath = StringUtility.Contact(targetDirectory, item); |
| | | var fromPath = StringUtility.Concat(ResourcesPath.Instance.StreamingAssetPath, item); |
| | | var toPath = StringUtility.Concat(targetDirectory, item); |
| | | |
| | | if (File.Exists(toPath)) |
| | | { |
| | |
| | | |
| | | if (VersionUtility.Instance.NeedDownAsset()) |
| | | { |
| | | var remoteURL = StringUtility.Contact(VersionUtility.Instance.versionInfo.GetResourcesURL(VersionConfig.Get().branch), Language.fixPath, "/config/PriorBundle.txt"); |
| | | var localURL = StringUtility.Contact(ResourcesPath.Instance.ExternalStorePath, "config/PriorBundle.txt"); |
| | | var remoteURL = StringUtility.Concat(VersionUtility.Instance.versionInfo.GetResourcesURL(VersionConfig.Get().branch), Language.fixPath, "/config/PriorBundle.txt"); |
| | | var localURL = StringUtility.Concat(ResourcesPath.Instance.ExternalStorePath, "config/PriorBundle.txt"); |
| | | var downloadTask = new DownloadHotTask(remoteURL, localURL); |
| | | downloadTask.BeginDownload(AssetVersionUtility.OnDownLoadPriorBundle); |
| | | |
| | |
| | | var byteStr = package.content.Split(' '); |
| | | if (byteStr.Length > 1) |
| | | { |
| | | package.name = StringUtility.Contact("H", byteStr[0], byteStr[1], "(未注册)"); |
| | | package.name = StringUtility.Concat("H", byteStr[0], byteStr[1], "(未注册)"); |
| | | } |
| | | } |
| | | else |
| | |
| | | { |
| | | for (int j = 0; j < package.fieldDetails.Count; j++) |
| | | { |
| | | line = StringUtility.Contact(line, "\t\t\t", package.fieldDetails[j], "\r\n"); |
| | | line = StringUtility.Concat(line, "\t\t\t", package.fieldDetails[j], "\r\n"); |
| | | } |
| | | } |
| | | |
| | |
| | | } |
| | | else |
| | | { |
| | | var assetName = StringUtility.Contact(SoNewBieGuide_Suffix, _id.ToString()); |
| | | var assetName = StringUtility.Concat(SoNewBieGuide_Suffix, _id.ToString()); |
| | | var assetInfo = new AssetInfo(bundleName, assetName); |
| | | config = AssetBundleUtility.Instance.Sync_LoadAsset(assetInfo) as NewBieGuideScriptableObject; |
| | | } |
| | |
| | | |
| | | public void InitBuiltInAsset() |
| | | { |
| | | var path = AssetVersionUtility.GetBuiltInAssetFilePath(StringUtility.Contact(AssetVersionUtility.EncodeFileName("builtin"), "_assetbundle"), false); |
| | | var path = AssetVersionUtility.GetBuiltInAssetFilePath(StringUtility.Concat(AssetVersionUtility.EncodeFileName("builtin"), "_assetbundle"), false); |
| | | var assetBundle = AssetBundle.LoadFromFile(path); |
| | | if (assetBundle == null) |
| | | { |
| | |
| | | // CloseAllIgnoreWindowConfig.Release(); |
| | | UnloadAssetBundle("builtin/scriptableobjects", true, false); |
| | | |
| | | var path = AssetVersionUtility.GetBuiltInAssetFilePath(StringUtility.Contact(AssetVersionUtility.EncodeFileName("builtin"), "_assetbundle"), false); |
| | | var path = AssetVersionUtility.GetBuiltInAssetFilePath(StringUtility.Concat(AssetVersionUtility.EncodeFileName("builtin"), "_assetbundle"), false); |
| | | var assetBundle = AssetBundle.LoadFromFile(path); |
| | | if (assetBundle == null) |
| | | { |
| | |
| | | |
| | | private async UniTask Co_LoadMainfestFile(string _category) |
| | | { |
| | | var path = AssetVersionUtility.GetAssetFilePath(StringUtility.Contact(AssetVersionUtility.EncodeFileName(_category), "_assetbundle"), false); |
| | | var path = AssetVersionUtility.GetAssetFilePath(StringUtility.Concat(AssetVersionUtility.EncodeFileName(_category), "_assetbundle"), false); |
| | | var _assetBundle = AssetBundle.LoadFromFile(path); |
| | | |
| | | if (_assetBundle == null) |
| | |
| | | #if UNITY_5||UNITY_5_3_OR_NEWER |
| | | assetBundleName = assetBundleName.ToLower(); |
| | | #endif |
| | | string _assembleName = StringUtility.Contact(assetBundleName, "@", assetName); |
| | | string _assembleName = StringUtility.Concat(assetBundleName, "@", assetName); |
| | | |
| | | if (JudgeExistAsset(assetBundleName, assetName) == false) |
| | | { |
| | |
| | | |
| | | m_AssetDict[assetBundleName][assetName] = asset; |
| | | |
| | | string _assembleName = StringUtility.Contact(assetBundleName, "@", assetName); |
| | | string _assembleName = StringUtility.Concat(assetBundleName, "@", assetName); |
| | | if (m_AssetInfoDict.ContainsKey(_assembleName) == false) |
| | | { |
| | | AssetInfo _assetInfo = new AssetInfo(assetBundleName, assetName); |
| | |
| | | if (!AssetSource.isUseAssetBundle) |
| | | { |
| | | #if UNITY_EDITOR |
| | | if (excludePngs.Contains(StringUtility.Contact(name, SPRITE_EXTENSION))) |
| | | if (excludePngs.Contains(StringUtility.Concat(name, SPRITE_EXTENSION))) |
| | | { |
| | | var path = StringUtility.Contact("Assets/ResourcesOut/BuiltIn/Sprites/", name, SPRITE_EXTENSION); |
| | | var path = StringUtility.Concat("Assets/ResourcesOut/BuiltIn/Sprites/", name, SPRITE_EXTENSION); |
| | | path = System.Text.RegularExpressions.Regex.Replace(path, @"[\p{C}]", ""); |
| | | sprite = UnityEditor.AssetDatabase.LoadAssetAtPath<Sprite>(path); |
| | | } |
| | |
| | | if (!AssetSource.isUseAssetBundle) |
| | | { |
| | | #if UNITY_EDITOR |
| | | var path = StringUtility.Contact("Assets/ResourcesOut/BuiltIn/Prefabs/", name, PREFAB_EXTENSION); |
| | | var path = StringUtility.Concat("Assets/ResourcesOut/BuiltIn/Prefabs/", name, PREFAB_EXTENSION); |
| | | prefab = UnityEditor.AssetDatabase.LoadAssetAtPath<GameObject>(path); |
| | | #endif |
| | | } |
| | |
| | | if (!AssetSource.isUseAssetBundle) |
| | | { |
| | | #if UNITY_EDITOR |
| | | var path = StringUtility.Contact("Assets/ResourcesOut/BuiltIn/Musics/", name, AUDIO_EXTENSION); |
| | | var path = StringUtility.Concat("Assets/ResourcesOut/BuiltIn/Musics/", name, AUDIO_EXTENSION); |
| | | audioClip = UnityEditor.AssetDatabase.LoadAssetAtPath<AudioClip>(path); |
| | | #endif |
| | | } |
| | |
| | | if (!AssetSource.isUseAssetBundle) |
| | | { |
| | | #if UNITY_EDITOR |
| | | var path = StringUtility.Contact("Assets/ResourcesOut/BuiltIn/AnimationClips/", name, ".anim"); |
| | | var path = StringUtility.Concat("Assets/ResourcesOut/BuiltIn/AnimationClips/", name, ".anim"); |
| | | clip = UnityEditor.AssetDatabase.LoadAssetAtPath<AnimationClip>(path); |
| | | #endif |
| | | } |
| | |
| | | if (!AssetSource.isUseAssetBundle) |
| | | { |
| | | #if UNITY_EDITOR |
| | | var path = StringUtility.Contact("Assets/ResourcesOut/BuiltIn/Materials/", name, ".mat"); |
| | | var path = StringUtility.Concat("Assets/ResourcesOut/BuiltIn/Materials/", name, ".mat"); |
| | | material = UnityEditor.AssetDatabase.LoadAssetAtPath<Material>(path); |
| | | #endif |
| | | } |
| | |
| | | if (!AssetSource.isUseAssetBundle) |
| | | { |
| | | #if UNITY_EDITOR |
| | | var resourcePath = StringUtility.Contact(ResourcesPath.ResourcesOutAssetPath, |
| | | var resourcePath = StringUtility.Concat(ResourcesPath.ResourcesOutAssetPath, |
| | | "BuiltIn/ScriptableObjects/", name, ".asset"); |
| | | |
| | | config = UnityEditor.AssetDatabase.LoadAssetAtPath<T>(resourcePath); |
| | |
| | | if (!AssetSource.isUseAssetBundle) |
| | | { |
| | | #if UNITY_EDITOR |
| | | var path = StringUtility.Contact(ResourcesPath.ResourcesOutAssetPath, |
| | | var path = StringUtility.Concat(ResourcesPath.ResourcesOutAssetPath, |
| | | "BuiltIn/Font/", fontName, ".ttf"); |
| | | font = UnityEditor.AssetDatabase.LoadAssetAtPath<Font>(path); |
| | | #endif |
| | |
| | | |
| | | public static Sprite LoadSprite(string _folder, string _file) |
| | | { |
| | | return ResManager.Instance.LoadAsset<Sprite>(StringUtility.Contact(ResourcesPath.UI_SPRITE_SUFFIX, "/", _folder), _file); |
| | | return ResManager.Instance.LoadAsset<Sprite>(StringUtility.Concat(ResourcesPath.UI_SPRITE_SUFFIX, "/", _folder), _file); |
| | | } |
| | | |
| | | public static void UnLoadSprite(string _iconKey) |
| | |
| | | var iconConfig = IconConfig.Get(_iconKey); |
| | | if (iconConfig != null) |
| | | { |
| | | var bundleName = StringUtility.Contact(ResourcesPath.UI_SPRITE_SUFFIX, "/", iconConfig.folder); |
| | | var bundleName = StringUtility.Concat(ResourcesPath.UI_SPRITE_SUFFIX, "/", iconConfig.folder); |
| | | ResManager.Instance.UnloadAsset(bundleName, iconConfig.sprite); |
| | | } |
| | | } |
| | |
| | | { |
| | | return null; |
| | | } |
| | | return ResManager.Instance.LoadAsset<Texture2D>(StringUtility.Contact(ResourcesPath.UI_TEXTURE_SUFFIX, "/" + iconConfig.folder), iconConfig.sprite); |
| | | return ResManager.Instance.LoadAsset<Texture2D>(StringUtility.Concat(ResourcesPath.UI_TEXTURE_SUFFIX, "/" + iconConfig.folder), iconConfig.sprite); |
| | | } |
| | | |
| | | public static Texture2D LoadTexture2DPNG(string name) |
| | | { |
| | | return ResManager.Instance.LoadAsset<Texture2D>(StringUtility.Contact(ResourcesPath.UI_TEXTURE_SUFFIX, "/FullScreenBg"), name + ".png", false); |
| | | return ResManager.Instance.LoadAsset<Texture2D>(StringUtility.Concat(ResourcesPath.UI_TEXTURE_SUFFIX, "/FullScreenBg"), name + ".png", false); |
| | | } |
| | | } |
| | |
| | | { |
| | | if (_completeFile) |
| | | { |
| | | var path = StringUtility.Contact(ResourcesPath.Instance.ExternalStorePath, m_RelativePath); |
| | | var path = StringUtility.Concat(ResourcesPath.Instance.ExternalStorePath, m_RelativePath); |
| | | var fileInfo = new FileInfo(path); |
| | | |
| | | if (!fileInfo.Exists) |
| | |
| | | { |
| | | if (extersion == ".manifest" || extersion == ".bytes" || extersion == ".txt" || extersion == ".dll") |
| | | { |
| | | var path = StringUtility.Contact(ResourcesPath.Instance.ExternalStorePath, m_RelativePath); |
| | | var path = StringUtility.Concat(ResourcesPath.Instance.ExternalStorePath, m_RelativePath); |
| | | var fileInfo = new FileInfo(path); |
| | | |
| | | if (!fileInfo.Exists || fileInfo.Length != size || md5 != FileExtersion.GetMD5HashFromFile(path)) |
| | |
| | | } |
| | | else if (string.IsNullOrEmpty(extersion) || extersion.Length == 0) |
| | | { |
| | | var path = StringUtility.Contact(ResourcesPath.Instance.ExternalStorePath, m_RelativePath); |
| | | var path = StringUtility.Concat(ResourcesPath.Instance.ExternalStorePath, m_RelativePath); |
| | | var fileInfo = new FileInfo(path); |
| | | |
| | | var manifestAssetVersion = AssetVersionUtility.GetAssetVersion(StringUtility.Contact(m_RelativePath, ".manifest")); |
| | | var manifestAssetVersion = AssetVersionUtility.GetAssetVersion(StringUtility.Concat(m_RelativePath, ".manifest")); |
| | | if (!fileInfo.Exists || fileInfo.Length != size || manifestAssetVersion == null || !manifestAssetVersion.CheckLocalFileValid(false)) |
| | | { |
| | | return false; |
| | |
| | | } |
| | | else |
| | | { |
| | | var path = StringUtility.Contact(ResourcesPath.Instance.ExternalStorePath, m_RelativePath); |
| | | var path = StringUtility.Concat(ResourcesPath.Instance.ExternalStorePath, m_RelativePath); |
| | | var fileInfo = new FileInfo(path); |
| | | if (!fileInfo.Exists || fileInfo.Length != size) |
| | | { |
| | |
| | | { |
| | | checkAssetCompleted = false; |
| | | Debug.LogFormat("开始获取资源版本文件:时间 {0}", DateTime.Now); |
| | | var assetVersionUrl = StringUtility.Contact(VersionUtility.Instance.versionInfo.GetResourcesURL(VersionConfig.Get().branch), Language.fixPath, "/AssetsVersion.txt"); |
| | | var assetVersionUrl = StringUtility.Concat(VersionUtility.Instance.versionInfo.GetResourcesURL(VersionConfig.Get().branch), Language.fixPath, "/AssetsVersion.txt"); |
| | | assetVerUrl = assetVersionUrl; |
| | | Debug.Log("http地址:assetVersionUrl " + assetVersionUrl); |
| | | HttpRequest.Instance.UnityWebRequestGet(assetVersionUrl, 5, OnGetAssetVersionFile); |
| | |
| | | // return false; |
| | | // } |
| | | |
| | | // if (!IsAssetValid(StringUtility.Contact("maps/", mapResConfig.MapResources.ToLower()))) |
| | | // if (!IsAssetValid(StringUtility.Concat("maps/", mapResConfig.MapResources.ToLower()))) |
| | | // { |
| | | // return false; |
| | | // } |
| | |
| | | // var npcConfig = NPCConfig.Get(item); |
| | | // if (npcConfig != null) |
| | | // { |
| | | // var assetbundleName = StringUtility.Contact("prefab_race_", npcConfig.MODE.ToLower()); |
| | | // if (!IsAssetValid(StringUtility.Contact("gmodels/", assetbundleName))) |
| | | // var assetbundleName = StringUtility.Concat("prefab_race_", npcConfig.MODE.ToLower()); |
| | | // if (!IsAssetValid(StringUtility.Concat("gmodels/", assetbundleName))) |
| | | // { |
| | | // return false; |
| | | // } |
| | |
| | | // { |
| | | // headString = name.Substring(0, index); |
| | | // name = name.Substring(index + 1); |
| | | // return StringUtility.Contact(headString, "/", new string(name.Reverse().ToArray()), "_aop"); |
| | | // return StringUtility.Concat(headString, "/", new string(name.Reverse().ToArray()), "_aop"); |
| | | // } |
| | | // else |
| | | // { |
| | | // headString = name.Substring(0, index); |
| | | // var ext = name.Substring(dotLastIndex); |
| | | // name = name.Substring(index + 1, dotLastIndex - index - 1); |
| | | // return StringUtility.Contact(headString, "/", new string(name.Reverse().ToArray()), "_aop", ext); |
| | | // return StringUtility.Concat(headString, "/", new string(name.Reverse().ToArray()), "_aop", ext); |
| | | // } |
| | | //} |
| | | //else |
| | | //{ |
| | | // int dotLastIndex = name.LastIndexOf("."); |
| | | // if (dotLastIndex == -1) |
| | | // return StringUtility.Contact(new string(name.Reverse().ToArray()), "_aop"); |
| | | // return StringUtility.Concat(new string(name.Reverse().ToArray()), "_aop"); |
| | | // else |
| | | // { |
| | | // var ext = name.Substring(dotLastIndex); |
| | | // name = name.Substring(0, dotLastIndex); |
| | | // return StringUtility.Contact(new string(name.Reverse().ToArray()), "_aop", ext); |
| | | // return StringUtility.Concat(new string(name.Reverse().ToArray()), "_aop", ext); |
| | | // } |
| | | //} |
| | | |
| | |
| | | // { |
| | | // headString = name.Substring(0, index); |
| | | // name = name.Substring(index + 1); |
| | | // return StringUtility.Contact(headString, "/", new string(name.Replace("_aop", "").Reverse().ToArray())); |
| | | // return StringUtility.Concat(headString, "/", new string(name.Replace("_aop", "").Reverse().ToArray())); |
| | | // } |
| | | // else |
| | | // { |
| | | // headString = name.Substring(0, index); |
| | | // var ext = name.Substring(dotLastIndex); |
| | | // name = name.Substring(index + 1, dotLastIndex - index - 1); |
| | | // return StringUtility.Contact(headString, "/", new string(name.Replace("_aop", "").Reverse().ToArray()), ext); |
| | | // return StringUtility.Concat(headString, "/", new string(name.Replace("_aop", "").Reverse().ToArray()), ext); |
| | | // } |
| | | //} |
| | | //else |
| | |
| | | { |
| | | if (reverse) |
| | | _assetKey = EncodeFileName(_assetKey); |
| | | var path = StringUtility.Contact(ResourcesPath.Instance.ExternalStorePath, _assetKey); |
| | | var path = StringUtility.Concat(ResourcesPath.Instance.ExternalStorePath, _assetKey); |
| | | if (!File.Exists(path)) |
| | | { |
| | | path = StringUtility.Contact(ResourcesPath.Instance.StreamingAssetPath, _assetKey); |
| | | path = StringUtility.Concat(ResourcesPath.Instance.StreamingAssetPath, _assetKey); |
| | | } |
| | | |
| | | return path; |
| | |
| | | { |
| | | if (reverse) |
| | | _assetKey = EncodeFileName(_assetKey); |
| | | var path = StringUtility.Contact(ResourcesPath.Instance.ExternalStorePath, _assetKey); |
| | | var path = StringUtility.Concat(ResourcesPath.Instance.ExternalStorePath, _assetKey); |
| | | if (!File.Exists(path)) |
| | | { |
| | | path = StringUtility.Contact(ResourcesPath.Instance.StreamingAssetPath, _assetKey); |
| | | path = StringUtility.Concat(ResourcesPath.Instance.StreamingAssetPath, _assetKey); |
| | | } |
| | | |
| | | return path; |
| | |
| | | for (int i = 0; i < tasks.Count; i++) |
| | | { |
| | | var assetVersion = tasks[i]; |
| | | var remoteURL = StringUtility.Contact(VersionUtility.Instance.versionInfo.GetResourcesURL(VersionConfig.Get().branch), Language.fixPath, "/", assetVersion.relativePath); |
| | | var localURL = StringUtility.Contact(ResourcesPath.Instance.ExternalStorePath, assetVersion.relativePath); |
| | | var remoteURL = StringUtility.Concat(VersionUtility.Instance.versionInfo.GetResourcesURL(VersionConfig.Get().branch), Language.fixPath, "/", assetVersion.relativePath); |
| | | var localURL = StringUtility.Concat(ResourcesPath.Instance.ExternalStorePath, assetVersion.relativePath); |
| | | DownloadHotMgr.Instance.AddTask(new DownloadHotTask(remoteURL, localURL)); |
| | | } |
| | | |
| | |
| | | // else |
| | | // { |
| | | // ExceptionCatcher.ReportException("游戏启动阶段文件下载失败", "文件名:" + _assetVersion.relativePath); |
| | | // var remoteURL = StringUtility.Contact(VersionUtility.Instance.versionInfo.GetResourcesURL(VersionConfig.Get().branch), "/", Language.Id, "/", _assetVersion.relativePath); |
| | | // var localURL = StringUtility.Contact(ResourcesPath.Instance.ExternalStorePath, _assetVersion.relativePath); |
| | | // var remoteURL = StringUtility.Concat(VersionUtility.Instance.versionInfo.GetResourcesURL(VersionConfig.Get().branch), "/", Language.Id, "/", _assetVersion.relativePath); |
| | | // var localURL = StringUtility.Concat(ResourcesPath.Instance.ExternalStorePath, _assetVersion.relativePath); |
| | | |
| | | // var remoteFile = new RemoteFile(); |
| | | // remoteFile.Init(remoteURL, localURL, _assetVersion); |
| | |
| | | |
| | | if (downLoadedSize >= DownLoadAndDiscompressHotTask.Instance.totalSize) |
| | | { |
| | | m_DownLoadSpeed.text = StringUtility.Contact(UnityEngine.Random.Range(5, 10).ToString(), "KB/S"); |
| | | m_DownLoadSpeed.text = StringUtility.Concat(UnityEngine.Random.Range(5, 10).ToString(), "KB/S"); |
| | | } |
| | | else |
| | | { |
| | |
| | | totalSize += assetVersion.size;//统计资源总大小 |
| | | |
| | | //添加下载任务 |
| | | var remoteURL = StringUtility.Contact(VersionUtility.Instance.versionInfo.GetResourcesURL(VersionConfig.Get().branch), Language.fixPath, "/", assetVersion.relativePath); |
| | | var localURL = StringUtility.Contact(ResourcesPath.Instance.ExternalStorePath, assetVersion.relativePath); |
| | | var remoteURL = StringUtility.Concat(VersionUtility.Instance.versionInfo.GetResourcesURL(VersionConfig.Get().branch), Language.fixPath, "/", assetVersion.relativePath); |
| | | var localURL = StringUtility.Concat(ResourcesPath.Instance.ExternalStorePath, assetVersion.relativePath); |
| | | DownloadHotMgr.Instance.AddTask(new DownloadHotTask(remoteURL, localURL, assetVersion)); |
| | | } |
| | | |
| | |
| | | else
|
| | | {
|
| | | var progress = Mathf.RoundToInt(InGameDownLoad.Instance.progress * 100);
|
| | | m_ProgressText.text = StringUtility.Contact(progress.ToString(), "%");
|
| | | m_ProgressText.text = StringUtility.Concat(progress.ToString(), "%");
|
| | | }
|
| | | }
|
| | | else
|
| | |
| | | else
|
| | | {
|
| | | var progress = Mathf.RoundToInt(InGameDownLoad.Instance.progress * 100);
|
| | | m_ProgressText.text = StringUtility.Contact(Mathf.Clamp(progress, 0, 99).ToString(), "%");
|
| | | m_ProgressText.text = StringUtility.Concat(Mathf.Clamp(progress, 0, 99).ToString(), "%");
|
| | | }
|
| | | }
|
| | | }
|
| | |
| | | |
| | | if (InGameDownLoad.Instance.showDownLoadedSize >= InGameDownLoad.Instance.showTotalSize) |
| | | { |
| | | m_DownLoadSpeed.text = StringUtility.Contact(UnityEngine.Random.Range(5, 10).ToString(), "KB/S"); |
| | | m_DownLoadSpeed.text = StringUtility.Concat(UnityEngine.Random.Range(5, 10).ToString(), "KB/S"); |
| | | } |
| | | else |
| | | { |
| | |
| | | txtLockInfo.SetActive(!isOpen); |
| | | |
| | | // 设置图标和名称 |
| | | string spriteAndLangKey = StringUtility.Contact("ChallengeTab", data.Index.ToString()); |
| | | string spriteAndLangKey = StringUtility.Concat("ChallengeTab", data.Index.ToString()); |
| | | imgIcon.SetSprite(spriteAndLangKey); |
| | | txtName.text = Language.Get(spriteAndLangKey); |
| | | |
| | |
| | | |
| | | public string GetChatTabName(ChatTab chatTab) |
| | | { |
| | | return Language.Get(StringUtility.Contact("ChatTab", ((int)chatTab).ToString())); |
| | | return Language.Get(StringUtility.Concat("ChatTab", ((int)chatTab).ToString())); |
| | | } |
| | | |
| | | public string GetChatTabSelectIcon(ChatTab chatTab, bool isSelect) |
| | | { |
| | | return StringUtility.Contact(isSelect ? "ChatTabSelect" : "ChatTabUnSelect", ((int)chatTab).ToString()); |
| | | return StringUtility.Concat(isSelect ? "ChatTabSelect" : "ChatTabUnSelect", ((int)chatTab).ToString()); |
| | | } |
| | | #endregion |
| | | #region 弹幕设置 |
| | | |
| | | private Dictionary<ChatChannel, bool> bulletSettingDict = new Dictionary<ChatChannel, bool>(); |
| | | |
| | | private string settingsKey { get { return StringUtility.Contact("BulletChatSettings_", PlayerDatas.Instance.PlayerId.ToString()); } } |
| | | private string settingsKey { get { return StringUtility.Concat("BulletChatSettings_", PlayerDatas.Instance.PlayerId.ToString()); } } |
| | | |
| | | // 设置特定频道的弹幕开关状态 |
| | | public void SetBulletSetting(ChatChannel channelType, bool isEnabled) |
| | |
| | | public static readonly string[] VERSION_URL = new string[] { |
| | | "http://xssgcenter.secondworld.net.cn:11000/center/appversion_new.php/?"}; |
| | | |
| | | public string androidRoot { get { return string.Empty;/*StringUtility.Contact(SDKUtils.Instance.DeviceRootPath, "/", VersionConfig.Get().bundleIdentifier);*/ } } |
| | | public string androidRoot { get { return string.Empty;/*StringUtility.Concat(SDKUtils.Instance.DeviceRootPath, "/", VersionConfig.Get().bundleIdentifier);*/ } } |
| | | |
| | | public DownloadHotTask downloadTask; |
| | | private string versionUrl; |
| | |
| | | |
| | | //tables["game"] = VersionConfig.Get().gameId; |
| | | |
| | | //var url = StringUtility.Contact(VERSION_URL[urlIndex % 2], HttpRequest.HashtablaToString(tables)); |
| | | //var url = StringUtility.Concat(VERSION_URL[urlIndex % 2], HttpRequest.HashtablaToString(tables)); |
| | | //urlIndex++; |
| | | //versionUrl = url; |
| | | //Debug.Log("http地址:versionUrl " + url); |
| | |
| | | return string.Empty; |
| | | var remoteURL = GetApkRemoteUrl(); |
| | | var fileName = Path.GetFileName(remoteURL); |
| | | return StringUtility.Contact(androidRoot, "/", fileName); |
| | | return StringUtility.Concat(androidRoot, "/", fileName); |
| | | } |
| | | |
| | | public string GetApkRemoteUrl() |
| | |
| | | {
|
| | | txtTitle.SetActive(true);
|
| | | txtInfo.SetActive(true);
|
| | | txtTitle.text = StringUtility.Contact(ItemConfig.Get(selectItemID).ItemName, " x", selectIemCount.ToString());
|
| | | txtTitle.text = StringUtility.Concat(ItemConfig.Get(selectItemID).ItemName, " x", selectIemCount.ToString());
|
| | | txtInfo.text = ItemConfig.Get(selectItemID).Description;
|
| | | }
|
| | | else
|
| | |
| | | itemCell.Init(new ItemCellModel((int)FirstChargeManager.Instance.heroItemID, true, 1)); |
| | | txtName.text = Language.Get("FirstCharge09", Language.Get("CommonQuality" + heroInfo.Quality),heroInfo.heroConfig.Name); |
| | | txtName.color = UIHelper.GetUIColorByFunc(heroInfo.Quality); |
| | | txtJob.text = Language.Get("FirstCharge06",Language.Get(StringUtility.Contact("HeroClass",heroInfo.heroConfig.Class.ToString()))); |
| | | txtJob.text = Language.Get("FirstCharge06",Language.Get(StringUtility.Concat("HeroClass",heroInfo.heroConfig.Class.ToString()))); |
| | | txtDesc.text = Language.Get("FirstCharge07",heroInfo.heroConfig.Desc); |
| | | } |
| | | |
| | |
| | | OnUpdateFirstChargeInfo?.Invoke(); |
| | | } |
| | | |
| | | public string key { get { return StringUtility.Contact("FirstCharge_AllRewardsClaimed_Time_", PlayerDatas.Instance.baseData.PlayerID.ToString()); } } |
| | | public string key { get { return StringUtility.Concat("FirstCharge_AllRewardsClaimed_Time_", PlayerDatas.Instance.baseData.PlayerID.ToString()); } } |
| | | |
| | | /// <summary> |
| | | /// 检查是否所有首充奖励都已领取,如果是,则将当前服务器时间保存到本地 |
| | |
| | | intarray[0] = TimeUtility.ServerNow.Month;
|
| | | intarray[1] = TimeUtility.ServerNow.Day;
|
| | | intarray[2] = _remind ? 1 : 0;
|
| | | LocalSave.SetIntArray(StringUtility.Contact(_remindKey, PlayerDatas.Instance.baseData.PlayerID.ToString()), intarray);
|
| | | LocalSave.SetIntArray(StringUtility.Concat(_remindKey, PlayerDatas.Instance.baseData.PlayerID.ToString()), intarray);
|
| | | }
|
| | |
|
| | | private void GetPlayerDayRemind()
|
| | |
| | |
|
| | | public void SetDayRemind(string _key)
|
| | | {
|
| | | var intarray = LocalSave.GetIntArray(StringUtility.Contact(_key, PlayerDatas.Instance.baseData.PlayerID.ToString()));
|
| | | var intarray = LocalSave.GetIntArray(StringUtility.Concat(_key, PlayerDatas.Instance.baseData.PlayerID.ToString()));
|
| | | if (dayRemindDic.ContainsKey(_key))
|
| | | {
|
| | | dayRemindDic[_key] = intarray;
|
| | |
| | | |
| | | public string GetCountryIconName(int index) |
| | | { |
| | | return StringUtility.Contact("herocountry", index.ToString()); |
| | | return StringUtility.Concat("herocountry", index.ToString()); |
| | | } |
| | | |
| | | public string GetJobIconName(int index) |
| | | { |
| | | return StringUtility.Contact("herojob", index.ToString()); |
| | | return StringUtility.Concat("herojob", index.ToString()); |
| | | } |
| | | |
| | | public int GetMaxLV(int quality) |
| | |
| | | // { |
| | | // for (var i = 0; i < 3; i++) |
| | | // { |
| | | // var sprite = BuiltInLoader.LoadSprite(StringUtility.Contact("Launch_", i + 1)); |
| | | // var sprite = BuiltInLoader.LoadSprite(StringUtility.Concat("Launch_", i + 1)); |
| | | // if (sprite != null) |
| | | // { |
| | | // backGrounds.Add(sprite); |
| | |
| | | case LaunchStage.SDKInit: |
| | | return Language.GetFromLocal(36); |
| | | case LaunchStage.AssetCopy: |
| | | return StringUtility.Contact(Language.GetFromLocal(37), "(", step.ToString(), ")"); |
| | | return StringUtility.Concat(Language.GetFromLocal(37), "(", step.ToString(), ")"); |
| | | case LaunchStage.AssetDecompress: |
| | | return StringUtility.Contact(Language.GetFromLocal(38), "(", step.ToString(), ")"); |
| | | return StringUtility.Concat(Language.GetFromLocal(38), "(", step.ToString(), ")"); |
| | | case LaunchStage.ClientVersion: |
| | | return Language.GetFromLocal(39); |
| | | case LaunchStage.CheckAsset: |
| | |
| | | case LaunchStage.AssetBundleInit: |
| | | return Language.GetFromLocal(42); |
| | | case LaunchStage.ConfigInit: |
| | | return StringUtility.Contact(Language.GetFromLocal(43), "(", step.ToString(), ")"); |
| | | return StringUtility.Concat(Language.GetFromLocal(43), "(", step.ToString(), ")"); |
| | | case LaunchStage.Complete: |
| | | return Language.GetFromLocal(44); |
| | | default: |
| | |
| | | m_IosProgressContainer.SetActive(LaunchInHot.progressInfo.stage != LaunchStage.DownLoad); |
| | | var remainder = ((int)Time.time) % 3; |
| | | var dot = remainder == 0 ? "." : remainder == 1 ? ".." : "..."; |
| | | m_IosProgressTip.text = StringUtility.Contact(Language.GetFromLocal(30), dot); |
| | | m_IosProgressTip.text = StringUtility.Concat(Language.GetFromLocal(30), dot); |
| | | } |
| | | else |
| | | { |
| | |
| | | //{ |
| | | // assetBuildTimeShowed = true; |
| | | // var totalMinute = (int)(AssetVersionUtility.assetsBuildTime - new DateTime(2018, 1, 1)).TotalMinutes; |
| | | // m_Version.text = StringUtility.Contact(VersionConfig.Get().version, "_", VersionConfig.Get().buildIndex, "_", totalMinute.ToString()); |
| | | // m_Version.text = StringUtility.Concat(VersionConfig.Get().version, "_", VersionConfig.Get().buildIndex, "_", totalMinute.ToString()); |
| | | //} |
| | | } |
| | | |
| | |
| | | // { |
| | | // for (var i = 0; i < 3; i++) |
| | | // { |
| | | // var sprite = BuiltInLoader.LoadSprite(StringUtility.Contact("Launch_", i + 1)); |
| | | // var sprite = BuiltInLoader.LoadSprite(StringUtility.Concat("Launch_", i + 1)); |
| | | // if (sprite != null) |
| | | // { |
| | | // backGrounds.Add(sprite); |
| | |
| | | { |
| | | tables["player"] = _accountName; |
| | | tables["lang"] = "vi"; |
| | | url = StringUtility.Contact(SERVERLIST_URL_PLAYER, "&", HttpRequest.HashtablaToString(tables)); |
| | | url = StringUtility.Concat(SERVERLIST_URL_PLAYER, "&", HttpRequest.HashtablaToString(tables)); |
| | | } |
| | | |
| | | HttpRequest.Instance.RequestHttpGet(url, HttpRequest.defaultHttpContentType, 1, OnGetServerListPlayer); |
| | |
| | | { |
| | | // 小于1天(但未过期):按精确的小时/分钟显示。 |
| | | TimeSpan t = TimeSpan.FromDays(days); |
| | | result = Language.Get("Mail12", StringUtility.Contact(" ", Language.Get("Mail13", t.Hours, t.Minutes))); |
| | | result = Language.Get("Mail12", StringUtility.Concat(" ", Language.Get("Mail13", t.Hours, t.Minutes))); |
| | | } |
| | | else |
| | | { |
| | |
| | | { |
| | | scrMail.m_Scorller.RefreshActiveCellViews(); |
| | | int personalMailCount = MailManager.Instance.GetMailCount(MailCategory.Personal); |
| | | txtCurrentMailCount.text = StringUtility.Contact(personalMailCount.ToString(), "/", MailManager.Instance.personalMailMaxLimitCount.ToString()); |
| | | txtCurrentMailCount.text = StringUtility.Concat(personalMailCount.ToString(), "/", MailManager.Instance.personalMailMaxLimitCount.ToString()); |
| | | } |
| | | |
| | | protected override void OpenSubUIByTabIndex() |
| | |
| | | btnClaimAll.SetActive(true); |
| | | transCurrentMailCount.SetActive(true); |
| | | int personalMailCount = MailManager.Instance.GetMailCount(MailCategory.Personal); |
| | | txtCurrentMailCount.text = StringUtility.Contact(personalMailCount.ToString(), "/", MailManager.Instance.personalMailMaxLimitCount.ToString()); |
| | | txtCurrentMailCount.text = StringUtility.Concat(personalMailCount.ToString(), "/", MailManager.Instance.personalMailMaxLimitCount.ToString()); |
| | | DisPlay(); |
| | | break; |
| | | case 1: |
| | |
| | | scrMail.Restart(); |
| | | } |
| | | int personalMailCount = MailManager.Instance.GetMailCount(MailCategory.Personal); |
| | | txtCurrentMailCount.text = StringUtility.Contact(personalMailCount.ToString(), "/", MailManager.Instance.personalMailMaxLimitCount.ToString()); |
| | | txtCurrentMailCount.text = StringUtility.Concat(personalMailCount.ToString(), "/", MailManager.Instance.personalMailMaxLimitCount.ToString()); |
| | | } |
| | | |
| | | |
| | |
| | | // if (fightPoint < (ulong)targetValue) |
| | | // { |
| | | // var label = dic.ContainsKey("replacelabel1") ? dic["replacelabel1"] : string.Empty; |
| | | // return UIHelper.AppendColor(TextColType.Red, StringUtility.Contact(label, fightPoint, "/", targetValue), colorType == 1); |
| | | // return UIHelper.AppendColor(TextColType.Red, StringUtility.Concat(label, fightPoint, "/", targetValue), colorType == 1); |
| | | // } |
| | | // else |
| | | // { |
| | |
| | | // if (property != 0) |
| | | // { |
| | | // var propertyConfig = PlayerPropertyConfig.Get(property); |
| | | // label = StringUtility.Contact(propertyConfig.Name, ":"); |
| | | // label = StringUtility.Concat(propertyConfig.Name, ":"); |
| | | // } |
| | | // return UIHelper.AppendColor(TextColType.Red, StringUtility.Contact(label, point, "/", targetValue), colorType == 1); |
| | | // return UIHelper.AppendColor(TextColType.Red, StringUtility.Concat(label, point, "/", targetValue), colorType == 1); |
| | | // } |
| | | // else |
| | | // { |
| | |
| | | // if (!satisfy) |
| | | // { |
| | | // var label = dic.ContainsKey("replacelabel1") ? dic["replacelabel1"] : string.Empty; |
| | | // return UIHelper.AppendColor(TextColType.Red, StringUtility.Contact(label, point, "/", targetValue), colorType == 1); |
| | | // return UIHelper.AppendColor(TextColType.Red, StringUtility.Concat(label, point, "/", targetValue), colorType == 1); |
| | | // } |
| | | // else |
| | | // { |
| | |
| | | var itemName = cfg.ItemName; |
| | | if (_dict.ContainsKey("chatsend")) |
| | | { |
| | | itemName = StringUtility.Contact("[", itemName, "]"); |
| | | itemName = StringUtility.Concat("[", itemName, "]"); |
| | | } |
| | | if (_dict.ContainsKey("count")) |
| | | { |
| | |
| | | int.TryParse(_dict["count"], out count); |
| | | if (count > 0) |
| | | { |
| | | itemName = StringUtility.Contact(itemName, "x", count.ToString()); |
| | | itemName = StringUtility.Concat(itemName, "x", count.ToString()); |
| | | } |
| | | } |
| | | var suitLabel = string.Empty; |
| | |
| | | } |
| | | // if (ItemLogicUtility.Instance.IsSuitEquip(id)) |
| | | // { |
| | | // suitLabel = StringUtility.Contact("<Suitname=", UIHelper.GetEquipSuitName(id, colorType == 1), "/>|"); |
| | | // suitLabel = StringUtility.Concat("<Suitname=", UIHelper.GetEquipSuitName(id, colorType == 1), "/>|"); |
| | | // } |
| | | } |
| | | return StringUtility.Contact(suitLabel, AppendColor(itemName, _itemColor, _dict)); |
| | | return StringUtility.Concat(suitLabel, AppendColor(itemName, _itemColor, _dict)); |
| | | } |
| | | else |
| | | { |
| | |
| | | var config = ItemConfig.Get(_id); |
| | | if (config != null) |
| | | { |
| | | return StringUtility.Contact(GetItemColorName(config.ItemColor), AppendColor(config.ItemName, config.ItemColor, _dict)); |
| | | return StringUtility.Concat(GetItemColorName(config.ItemColor), AppendColor(config.ItemName, config.ItemColor, _dict)); |
| | | } |
| | | } |
| | | } |
| | |
| | | }
|
| | | else if (!operation.SatisfyOpenCondition())
|
| | | {
|
| | | SysNotifyMgr.Instance.ShowTip(StringUtility.Contact("OperationLevelLimit_", type.ToString()), operation.limitLv);
|
| | | SysNotifyMgr.Instance.ShowTip(StringUtility.Concat("OperationLevelLimit_", type.ToString()), operation.limitLv);
|
| | | }
|
| | | }
|
| | | else
|
| | |
| | | return $"{month}/{day}";
|
| | |
|
| | |
|
| | | //var yearString = StringUtility.Contact(year, Language.Get("Year"));
|
| | | //return StringUtility.Contact(showYear ? yearString : string.Empty, month, Language.Get("Month"), day, Language.Get("Day"));
|
| | | //var yearString = StringUtility.Concat(year, Language.Get("Year"));
|
| | | //return StringUtility.Concat(showYear ? yearString : string.Empty, month, Language.Get("Month"), day, Language.Get("Day"));
|
| | | }
|
| | |
|
| | | public static int operator -(OperationDate x, OperationDate y)
|
| | |
| | | public static string GetAvatarBgColorStr(int faceID)
|
| | | {
|
| | | int bgColor = GetAvatarBgColor(faceID);
|
| | | return StringUtility.Contact("AvatarBgColor", bgColor.ToString());
|
| | | return StringUtility.Concat("AvatarBgColor", bgColor.ToString());
|
| | | }
|
| | | } |
| | |
| | | if (attrPerStarAddList.IsNullOrEmpty() || attrIDList.Length != initAttrValueList.Length || attrPerStarAddList.Length <= index) |
| | | return; |
| | | int attrPerStarAdd = attrPerStarAddList[index]; |
| | | txtAddNext.text = Language.Get("PhantasmPavilion12", UIHelper.AppendColor(TextColType.LightGreen, StringUtility.Contact("+", PlayerPropertyConfig.GetValueDescription(attrID, attrPerStarAdd)))); |
| | | txtAddNext.text = Language.Get("PhantasmPavilion12", UIHelper.AppendColor(TextColType.LightGreen, StringUtility.Concat("+", PlayerPropertyConfig.GetValueDescription(attrID, attrPerStarAdd)))); |
| | | } |
| | | } |
| | | |
| | |
| | | public string GetModelBgColorStr(int id) |
| | | { |
| | | int bgColor = GetModelBgColor(id); |
| | | return StringUtility.Contact("ModelBgColor", bgColor.ToString()); |
| | | return StringUtility.Concat("ModelBgColor", bgColor.ToString()); |
| | | } |
| | | } |
| | |
| | | |
| | | } |
| | | |
| | | string modelkey { get { return StringUtility.Contact("PhantasmPavilion_Redponit_Model_", PlayerDatas.Instance.PlayerId.ToString()); } } |
| | | string facekey { get { return StringUtility.Contact("PhantasmPavilion_Redponit_Face_", PlayerDatas.Instance.PlayerId.ToString()); } } |
| | | string modelkey { get { return StringUtility.Concat("PhantasmPavilion_Redponit_Model_", PlayerDatas.Instance.PlayerId.ToString()); } } |
| | | string facekey { get { return StringUtility.Concat("PhantasmPavilion_Redponit_Face_", PlayerDatas.Instance.PlayerId.ToString()); } } |
| | | public void SaveLocal() |
| | | { |
| | | LocalSave.SetIntArray(modelkey, newHeroIDModelList.ToArray()); |
| | |
| | | if (isCanStarAdd && manager.TryGetInfo(type, id, out var info) && |
| | | state == PhantasmPavilionState.Activated && info.Star > 0) |
| | | { |
| | | txtName.text = StringUtility.Contact(name, " ", Language.Get("L1113", info.Star)); |
| | | txtName.text = StringUtility.Concat(name, " ", Language.Get("L1113", info.Star)); |
| | | } |
| | | else |
| | | { |
| | |
| | | tables["roleid"] = UIHelper.ServerStringTrim(PlayerDatas.Instance.baseData.PlayerName); |
| | | tables["level"] = PlayerDatas.Instance.baseData.LV.ToString(); |
| | | tables["viplevel"] = PlayerDatas.Instance.baseData.VIPLv.ToString(); |
| | | HttpRequest.Instance.RequestHttpGet(StringUtility.Contact(exchangeUrl, HttpRequest.HashtablaToString(tables)), HttpRequest.defaultHttpContentType, 1, null); |
| | | HttpRequest.Instance.RequestHttpGet(StringUtility.Concat(exchangeUrl, HttpRequest.HashtablaToString(tables)), HttpRequest.defaultHttpContentType, 1, null); |
| | | } |
| | | // if (passward.Length > 1) |
| | | // { |
| | |
| | | |
| | | int randomNameIndex1 = UnityEngine.Random.Range(0, randomNameList1.Count - 1); |
| | | int randomNameIndex2 = UnityEngine.Random.Range(0, randomNameList2.Count - 1); |
| | | return StringUtility.Contact(randomNameList1[randomNameIndex1], randomNameList2[randomNameIndex2]); |
| | | return StringUtility.Concat(randomNameList1[randomNameIndex1], randomNameList2[randomNameIndex2]); |
| | | } |
| | | |
| | | public bool CheckNameLimit(string name, out int errorCode) |
| | |
| | | value = UIHelper.ServerStringTrim(value); |
| | | if (value != null && value.Length > 0) |
| | | { |
| | | setting = StringUtility.Contact(value, setting.Substring(value.Length, setting.Length - value.Length)); |
| | | setting = StringUtility.Concat(value, setting.Substring(value.Length, setting.Length - value.Length)); |
| | | cacheSetting = setting; |
| | | PlayerDatas.Instance.baseData.Setting = setting; |
| | | } |
| | |
| | | int state = GetShopIDState(shopID);
|
| | | if (state == 1 || state == 3)
|
| | | {
|
| | | SysNotifyMgr.Instance.ShowTip(StringUtility.Contact("StoreTip", state.ToString()));
|
| | | SysNotifyMgr.Instance.ShowTip(StringUtility.Concat("StoreTip", state.ToString()));
|
| | | return false;
|
| | | }
|
| | | return true;
|
| | |
| | | { |
| | | imgRank.SetActive(true); |
| | | txtRank.SetActive(false); |
| | | imgRank.SetSprite(StringUtility.Contact("Rank", rank.ToString())); |
| | | imgRank.SetSprite(StringUtility.Concat("Rank", rank.ToString())); |
| | | txtRank.text = rank.ToString(); |
| | | } |
| | | else |
| | |
| | | } |
| | | else if (mins > 0) |
| | | { |
| | | return StringUtility.Contact(mins.ToString(), Language.Get("L1073"), seconds.ToString(), Language.Get("L1075")); |
| | | return StringUtility.Concat(mins.ToString(), Language.Get("L1073"), seconds.ToString(), Language.Get("L1075")); |
| | | } |
| | | else |
| | | { |
| | | return StringUtility.Contact(seconds.ToString(), Language.Get("L1075")); |
| | | return StringUtility.Concat(seconds.ToString(), Language.Get("L1075")); |
| | | } |
| | | } |
| | | |
| | |
| | | { |
| | | int mins = _seconds % 3600 / 60; |
| | | int seconds = _seconds % 60; |
| | | return StringUtility.Contact(mins.ToString("D2"), ":", seconds.ToString("D2")); |
| | | return StringUtility.Concat(mins.ToString("D2"), ":", seconds.ToString("D2")); |
| | | } |
| | | |
| | | //例子;不足的不显示 如0天0:xx:xx:,显示为xx:xx |
| | |
| | | int days = _seconds / 86400; |
| | | if (days > 0) |
| | | { |
| | | return StringUtility.Contact(days.ToString(), Language.Get("L1074")); |
| | | return StringUtility.Concat(days.ToString(), Language.Get("L1074")); |
| | | } |
| | | int hours = _seconds % 86400 / 3600; |
| | | if (hours > 0) |
| | | { |
| | | return StringUtility.Contact(hours.ToString(), Language.Get("Hour")); |
| | | return StringUtility.Concat(hours.ToString(), Language.Get("Hour")); |
| | | } |
| | | int mins = Mathf.CeilToInt(_seconds % 3600 / 60.0f); |
| | | if (mins > 0) |
| | | { |
| | | return StringUtility.Contact(mins.ToString(), Language.Get("Minute")); |
| | | return StringUtility.Concat(mins.ToString(), Language.Get("Minute")); |
| | | } |
| | | return StringUtility.Contact("1", Language.Get("Minute")); |
| | | return StringUtility.Concat("1", Language.Get("Minute")); |
| | | } |
| | | |
| | | |
| | |
| | | { |
| | | if (hours == 0) |
| | | { |
| | | return StringUtility.Contact(days.ToString(), Language.Get("L1074")); |
| | | return StringUtility.Concat(days.ToString(), Language.Get("L1074")); |
| | | } |
| | | return StringUtility.Contact(days.ToString(), Language.Get("L1074"), hours.ToString(), Language.Get("L1072")); |
| | | return StringUtility.Concat(days.ToString(), Language.Get("L1074"), hours.ToString(), Language.Get("L1072")); |
| | | } |
| | | else if (hours > 0) |
| | | { |
| | | if (mins == 0) |
| | | { |
| | | return StringUtility.Contact(hours.ToString(), Language.Get("L1072")); |
| | | return StringUtility.Concat(hours.ToString(), Language.Get("L1072")); |
| | | } |
| | | return StringUtility.Contact(hours.ToString(), Language.Get("L1072"), mins.ToString(), Language.Get("L1073")); |
| | | return StringUtility.Concat(hours.ToString(), Language.Get("L1072"), mins.ToString(), Language.Get("L1073")); |
| | | } |
| | | else if (mins > 0) |
| | | { |
| | | return StringUtility.Contact(mins.ToString(), Language.Get("L1073")); |
| | | return StringUtility.Concat(mins.ToString(), Language.Get("L1073")); |
| | | } |
| | | return StringUtility.Contact(seconds.ToString(), Language.Get("L1075")); |
| | | return StringUtility.Concat(seconds.ToString(), Language.Get("L1075")); |
| | | } |
| | | |
| | | |
| | |
| | | float seconds = (float)_seconds % 60; |
| | | if (days >= 1) |
| | | { |
| | | return StringUtility.Contact(Mathf.CeilToInt(days).ToString(), Language.Get("L1074")); |
| | | return StringUtility.Concat(Mathf.CeilToInt(days).ToString(), Language.Get("L1074")); |
| | | } |
| | | else if (hours >= 1) |
| | | { |
| | | return StringUtility.Contact(Mathf.CeilToInt(hours).ToString(), Language.Get("L1072")); |
| | | return StringUtility.Concat(Mathf.CeilToInt(hours).ToString(), Language.Get("L1072")); |
| | | } |
| | | else if (mins >= 1) |
| | | { |
| | | return StringUtility.Contact(mins.ToString(), Language.Get("L1073")); |
| | | return StringUtility.Concat(mins.ToString(), Language.Get("L1073")); |
| | | } |
| | | else |
| | | { |
| | | return StringUtility.Contact(seconds.ToString(), Language.Get("L1075")); |
| | | return StringUtility.Concat(seconds.ToString(), Language.Get("L1075")); |
| | | } |
| | | } |
| | | |
| | |
| | | { |
| | | // 暂不考虑富文本的情况 |
| | | // 不需要物品的情况补充 |
| | | // string iconKey = StringUtility.Contact("Money_Type_", moneyType); |
| | | // string iconKey = StringUtility.Concat("Money_Type_", moneyType); |
| | | Debug.LogError("MoneyDisplayModel 未配置货币类型:" + moneyType); |
| | | } |
| | | } |
| | |
| | | { |
| | | if (attrName.Length == 2) |
| | | { |
| | | suitStr = StringUtility.Contact(suitStr, attrName[i].ToString(), " "); |
| | | suitStr = StringUtility.Concat(suitStr, attrName[i].ToString(), " "); |
| | | } |
| | | else if (attrName.Length == 3) |
| | | { |
| | | suitStr = StringUtility.Contact(suitStr, attrName[i].ToString(), " "); |
| | | suitStr = StringUtility.Concat(suitStr, attrName[i].ToString(), " "); |
| | | } |
| | | else |
| | | { |
| | | suitStr = StringUtility.Contact(suitStr, attrName[i].ToString()); |
| | | suitStr = StringUtility.Concat(suitStr, attrName[i].ToString()); |
| | | } |
| | | } |
| | | else |
| | | { |
| | | suitStr = StringUtility.Contact(suitStr, attrName[i].ToString()); |
| | | suitStr = StringUtility.Concat(suitStr, attrName[i].ToString()); |
| | | } |
| | | } |
| | | return suitStr; |
| | |
| | | |
| | | if (num >= T) |
| | | { |
| | | return StringUtility.Contact(FormatWithoutRounding(num / T, 2), Language.Get("L1070_0")); |
| | | return StringUtility.Concat(FormatWithoutRounding(num / T, 2), Language.Get("L1070_0")); |
| | | } |
| | | else if (num >= B) |
| | | { |
| | | return StringUtility.Contact(FormatWithoutRounding(num / B, 2), Language.Get("L1070_1")); |
| | | return StringUtility.Concat(FormatWithoutRounding(num / B, 2), Language.Get("L1070_1")); |
| | | } |
| | | else if (num >= M) |
| | | { |
| | | return StringUtility.Contact(FormatWithoutRounding(num / M, decimalPlaces), Language.Get("L1070")); |
| | | return StringUtility.Concat(FormatWithoutRounding(num / M, decimalPlaces), Language.Get("L1070")); |
| | | } |
| | | else if (num >= K) |
| | | { |
| | | return StringUtility.Contact(FormatWithoutRounding(num / K, decimalPlaces), Language.Get("L1071")); |
| | | return StringUtility.Concat(FormatWithoutRounding(num / K, decimalPlaces), Language.Get("L1071")); |
| | | } |
| | | else |
| | | { |
| | |
| | | |
| | | if (num >= T) |
| | | { |
| | | return StringUtility.Contact(FormatWithoutRounding(num / T, 2), "t"); |
| | | return StringUtility.Concat(FormatWithoutRounding(num / T, 2), "t"); |
| | | } |
| | | else if (num >= B) |
| | | { |
| | | return StringUtility.Contact(FormatWithoutRounding(num / B, 2), "b"); |
| | | return StringUtility.Concat(FormatWithoutRounding(num / B, 2), "b"); |
| | | } |
| | | else if (num >= M) |
| | | { |
| | | return StringUtility.Contact(FormatWithoutRounding(num / M, 1), "m"); |
| | | return StringUtility.Concat(FormatWithoutRounding(num / M, 1), "m"); |
| | | } |
| | | else if (num >= K) |
| | | { |
| | | return StringUtility.Contact(FormatWithoutRounding(num / K, 1), "k"); |
| | | return StringUtility.Concat(FormatWithoutRounding(num / K, 1), "k"); |
| | | } |
| | | else |
| | | { |
| | |
| | | // switch (crossDanLVConfig.DanType) |
| | | // { |
| | | // case 0: |
| | | // return StringUtility.Contact("<color=#", bright ? "666666" : "dddddd", ">", name, "</color>"); |
| | | // return StringUtility.Concat("<color=#", bright ? "666666" : "dddddd", ">", name, "</color>"); |
| | | // case 1: |
| | | // return StringUtility.Contact("<color=#", bright ? "9460ff" : "7999ff", ">", name, "</color>"); |
| | | // return StringUtility.Concat("<color=#", bright ? "9460ff" : "7999ff", ">", name, "</color>"); |
| | | // case 2: |
| | | // return StringUtility.Contact("<color=#", bright ? "0066ff" : "00c6ff", ">", name, "</color>"); |
| | | // return StringUtility.Concat("<color=#", bright ? "0066ff" : "00c6ff", ">", name, "</color>"); |
| | | // case 3: |
| | | // return StringUtility.Contact("<color=#", bright ? "00b337" : "66ff00", ">", name, "</color>"); |
| | | // return StringUtility.Concat("<color=#", bright ? "00b337" : "66ff00", ">", name, "</color>"); |
| | | // case 4: |
| | | // return StringUtility.Contact("<color=#", bright ? "ff6600" : "ff9000", ">", name, "</color>"); |
| | | // return StringUtility.Concat("<color=#", bright ? "ff6600" : "ff9000", ">", name, "</color>"); |
| | | // case 5: |
| | | // return StringUtility.Contact("<color=#", bright ? "ff0000" : "ff0000", ">", name, "</color>"); |
| | | // return StringUtility.Concat("<color=#", bright ? "ff0000" : "ff0000", ">", name, "</color>"); |
| | | // case 6: |
| | | // return StringUtility.Contact("<color=#", bright ? "ff00f6" : "f000ff", ">", name, "</color>"); |
| | | // return StringUtility.Concat("<color=#", bright ? "ff00f6" : "f000ff", ">", name, "</color>"); |
| | | // } |
| | | // return name; |
| | | // } |
| | |
| | | case TextColType.White: |
| | | return StringUtility.Concat("<color=#", bright ? "ffffff" : "ffffff", ">", msg, "</color>"); |
| | | case TextColType.titleSelectColor: |
| | | return StringUtility.Contact("<color=#7F4139>", msg, "</color>"); |
| | | return StringUtility.Concat("<color=#7F4139>", msg, "</color>"); |
| | | case TextColType.titleUnSelectColor: |
| | | return StringUtility.Contact("<color=#6E5C60>", msg, "</color>"); |
| | | return StringUtility.Concat("<color=#6E5C60>", msg, "</color>"); |
| | | case TextColType.Red: |
| | | return StringUtility.Concat("<color=#", bright ? "ea261e" : "ea261e", ">", msg, "</color>"); |
| | | case TextColType.Pink: |
| | |
| | | case TextColType.Green: |
| | | return StringUtility.Concat("<color=#", bright ? "248B12" : "2ae337", ">", msg, "</color>"); |
| | | case TextColType.NavyBrown: |
| | | return StringUtility.Contact("<color=#6e4c31>", msg, "</color>"); |
| | | return StringUtility.Concat("<color=#6e4c31>", msg, "</color>"); |
| | | case TextColType.DarkGreen: |
| | | return StringUtility.Contact("<color=#248B12>", msg, "</color>"); |
| | | return StringUtility.Concat("<color=#248B12>", msg, "</color>"); |
| | | case TextColType.Black: |
| | | return StringUtility.Contact("<color=#000000>", msg, "</color>"); |
| | | return StringUtility.Concat("<color=#000000>", msg, "</color>"); |
| | | case TextColType.LightWhite: |
| | | return StringUtility.Contact("<color=f5f646>", msg, "</color>"); |
| | | return StringUtility.Concat("<color=f5f646>", msg, "</color>"); |
| | | case TextColType.LightGreen: |
| | | return StringUtility.Contact("<color=#8ddc11>", msg, "</color>"); |
| | | return StringUtility.Concat("<color=#8ddc11>", msg, "</color>"); |
| | | case TextColType.Gray: |
| | | return StringUtility.Contact("<color=#bbbbbb>", msg, "</color>"); |
| | | return StringUtility.Concat("<color=#bbbbbb>", msg, "</color>"); |
| | | case TextColType.NavyGray: |
| | | return StringUtility.Contact("<color=#797979>", msg, "</color>"); |
| | | return StringUtility.Concat("<color=#797979>", msg, "</color>"); |
| | | case TextColType.lightYellow: |
| | | return StringUtility.Contact("<color=#fcedb9>", msg, "</color>"); |
| | | return StringUtility.Concat("<color=#fcedb9>", msg, "</color>"); |
| | | case TextColType.NavyYellow: |
| | | return StringUtility.Contact("<color=#f2ee02>", msg, "</color>"); |
| | | return StringUtility.Concat("<color=#f2ee02>", msg, "</color>"); |
| | | case TextColType.itemjingliang: |
| | | // 729de4 精良 |
| | | return StringUtility.Contact("<color=#729de4>", msg, "</color>"); |
| | | return StringUtility.Concat("<color=#729de4>", msg, "</color>"); |
| | | case TextColType.itemxiyou: |
| | | // c87bfa稀有 |
| | | return StringUtility.Contact("<color=#c87bfa>", msg, "</color>"); |
| | | return StringUtility.Concat("<color=#c87bfa>", msg, "</color>"); |
| | | case TextColType.itemshishi: |
| | | // f6de56 史诗 |
| | | return StringUtility.Contact("<color=#f6de56>", msg, "</color>"); |
| | | return StringUtility.Concat("<color=#f6de56>", msg, "</color>"); |
| | | case TextColType.itemchuanqi: |
| | | // fe8534 传奇 |
| | | return StringUtility.Contact("<color=#fe8534>", msg, "</color>"); |
| | | return StringUtility.Concat("<color=#fe8534>", msg, "</color>"); |
| | | case TextColType.itemshenhua: |
| | | // fe4a47 神话 |
| | | return StringUtility.Contact("<color=#fe4a47>", msg, "</color>"); |
| | | return StringUtility.Concat("<color=#fe4a47>", msg, "</color>"); |
| | | case TextColType.itemwuxia: |
| | | // eb5ce9 无瑕 |
| | | return StringUtility.Contact("<color=#eb5ce9>", msg, "</color>"); |
| | | return StringUtility.Concat("<color=#eb5ce9>", msg, "</color>"); |
| | | case TextColType.itemanjin: |
| | | // f9e29f 暗金 |
| | | return StringUtility.Contact("<color=#f9e29f>", msg, "</color>"); |
| | | return StringUtility.Concat("<color=#f9e29f>", msg, "</color>"); |
| | | case TextColType.itemjueyi: |
| | | // cdfef2 绝艺 |
| | | return StringUtility.Contact("<color=#cdfef2>", msg, "</color>"); |
| | | return StringUtility.Concat("<color=#cdfef2>", msg, "</color>"); |
| | | case TextColType.itemyuanzu: |
| | | // dfbbed 元祖 |
| | | return StringUtility.Contact("<color=#dfbbed>", msg, "</color>"); |
| | | return StringUtility.Concat("<color=#dfbbed>", msg, "</color>"); |
| | | case TextColType.itembuxiu: |
| | | // 5eeff2 不朽 |
| | | return StringUtility.Contact("<color=#5eeff2>", msg, "</color>"); |
| | | return StringUtility.Concat("<color=#5eeff2>", msg, "</color>"); |
| | | case TextColType.itemyonghen: |
| | | // f5b4ea 永恒 |
| | | return StringUtility.Contact("<color=#f5b4ea>", msg, "</color>"); |
| | | return StringUtility.Concat("<color=#f5b4ea>", msg, "</color>"); |
| | | } |
| | | return msg; |
| | | } |
| | |
| | | // switch (config.Quality) |
| | | // { |
| | | // case 1: |
| | | // return StringUtility.Contact("<color=#", bright ? "666666" : "dddddd", ">", msg, "</color>"); |
| | | // return StringUtility.Concat("<color=#", bright ? "666666" : "dddddd", ">", msg, "</color>"); |
| | | // case 2: |
| | | // return StringUtility.Contact("<color=#", bright ? "00b337" : "66ff00", ">", msg, "</color>"); |
| | | // return StringUtility.Concat("<color=#", bright ? "00b337" : "66ff00", ">", msg, "</color>"); |
| | | // case 3: |
| | | // return StringUtility.Contact("<color=#", bright ? "0066ff" : "00c6ff", ">", msg, "</color>"); |
| | | // return StringUtility.Concat("<color=#", bright ? "0066ff" : "00c6ff", ">", msg, "</color>"); |
| | | // case 4: |
| | | // return StringUtility.Contact("<color=#", bright ? "ff00f6" : "f000ff", ">", msg, "</color>"); |
| | | // return StringUtility.Concat("<color=#", bright ? "ff00f6" : "f000ff", ">", msg, "</color>"); |
| | | // case 5: |
| | | // return StringUtility.Contact("<color=#", bright ? "ff6600" : "ff9000", ">", msg, "</color>"); |
| | | // return StringUtility.Concat("<color=#", bright ? "ff6600" : "ff9000", ">", msg, "</color>"); |
| | | // case 6: |
| | | // return StringUtility.Contact("<color=#", bright ? "ff0000" : "ff0000", ">", msg, "</color>"); |
| | | // return StringUtility.Concat("<color=#", bright ? "ff0000" : "ff0000", ">", msg, "</color>"); |
| | | // default: |
| | | // return msg; |
| | | // } |
| | |
| | | // { |
| | | // return string.Empty; |
| | | // } |
| | | // return StringUtility.Contact(GetEquipSuitName(itmeId, bright), itemConfig.ItemName); |
| | | // return StringUtility.Concat(GetEquipSuitName(itmeId, bright), itemConfig.ItemName); |
| | | // } |
| | | |
| | | public static string GetStar(int star) |
| | |
| | | GUILayout.BeginHorizontal(); |
| | | var _copyTarget = _target.copyTargets[i]; |
| | | _copyTarget.ok = EditorGUILayout.Toggle("是否替换", _copyTarget.ok, GUILayout.Width(40)); |
| | | EditorGUILayout.LabelField(StringUtility.Contact("Image", _copyTarget.images.Count.ToString())); |
| | | EditorGUILayout.LabelField(StringUtility.Contact("Text", _copyTarget.texts.Count.ToString())); |
| | | EditorGUILayout.LabelField(StringUtility.Concat("Image", _copyTarget.images.Count.ToString())); |
| | | EditorGUILayout.LabelField(StringUtility.Concat("Text", _copyTarget.texts.Count.ToString())); |
| | | GUILayout.EndHorizontal(); |
| | | } |
| | | GUILayout.EndScrollView(); |