| | |
| | | if (isOpenPrompting)
|
| | | {
|
| | | int recycleNum = playerPack.GetItemCountByID(PackType.rptItem, itemId);
|
| | | ConfirmCancel.IconConfirmCancel(Language.Get("Mail101"), Language.Get("BlastFurnace114", recycleNum, UIHelper.GetTextColorByItemColor(itemConfig.ItemColor, itemConfig.ItemName), exp * recycleNum), itemConfig.ID,
|
| | | ConfirmCancel.IconConfirmCancel(Language.Get("Mail101"), Language.Get("BlastFurnace114", recycleNum, UIHelper.AppendStringColor(itemConfig.ItemColor, itemConfig.ItemName), exp * recycleNum), itemConfig.ID,
|
| | | playerPack.GetItemCountByID(PackType.rptItem, itemConfig.ID), 0, "", Language.Get("ConfirmCancel102"), (bool isOk, bool isToggle) =>
|
| | | {
|
| | | if (isOk)
|
| | |
| | | List<int> nums = null;
|
| | | if (CheckIsNoBindDrug(itemId, out noBindNum, out indexs, out nums))
|
| | | {
|
| | | ConfirmCancel.ShowPopConfirm(Language.Get("Mail101"), Language.Get("BlastFurnace115", noBindNum, UIHelper.GetTextColorByItemColor(itemConfig.ItemColor, itemConfig.ItemName)),
|
| | | ConfirmCancel.ShowPopConfirm(Language.Get("Mail101"), Language.Get("BlastFurnace115", noBindNum, UIHelper.AppendStringColor(itemConfig.ItemColor, itemConfig.ItemName)),
|
| | | (bool isRecycle) =>
|
| | | {
|
| | | if (isRecycle)
|
| | |
| | | List<int> nums = null;
|
| | | if (CheckIsNoBindDrug(itemId, out noBindNum, out indexs, out nums))
|
| | | {
|
| | | ConfirmCancel.ShowPopConfirm(Language.Get("Mail101"), Language.Get("BlastFurnace115", noBindNum, UIHelper.GetTextColorByItemColor(itemConfig.ItemColor, itemConfig.ItemName)),
|
| | | ConfirmCancel.ShowPopConfirm(Language.Get("Mail101"), Language.Get("BlastFurnace115", noBindNum, UIHelper.AppendStringColor(itemConfig.ItemColor, itemConfig.ItemName)),
|
| | | (bool isRecycle) =>
|
| | | {
|
| | | if (isRecycle)
|
| | |
| | | }
|
| | | else
|
| | | {
|
| | | itemCell.countText.text = StringUtility.Contact(UIHelper.GetTextColorByItemColor(TextColType.Red, remainNum.ToString()),
|
| | | itemCell.countText.text = StringUtility.Contact(UIHelper.AppendStringColor(TextColType.Red, remainNum.ToString()),
|
| | | "/" + canBuyCnt.ToString());
|
| | | sellOutImg.gameObject.SetActive(true);
|
| | | }
|
| | |
| | | float progress = (float)Math.Round(playerPack.GetAlchemyProgress(alchemyModel), 2);
|
| | | if(progress > 0)
|
| | | {
|
| | | progressValue.text = UIHelper.GetTextColorByItemColor(TextColType.Green, StringUtility.Contact(progress, "%"));
|
| | | progressValue.text = UIHelper.AppendStringColor(TextColType.Green, StringUtility.Contact(progress, "%"));
|
| | | }
|
| | | else
|
| | | {
|
| | |
| | | fireChooseCell.addBtn.gameObject.SetActive(true);
|
| | | if (num >= alchemySpecModel.SpecialMateriaNUM)
|
| | | {
|
| | | fireChooseCell.itemCell.countText.text = UIHelper.GetTextColorByItemColor(TextColType.Green,num.ToString(),true) + "/" + alchemySpecModel.SpecialMateriaNUM;
|
| | | fireChooseCell.itemCell.countText.text = UIHelper.AppendStringColor(TextColType.Green,num.ToString(),true) + "/" + alchemySpecModel.SpecialMateriaNUM;
|
| | | }
|
| | | else
|
| | | {
|
| | | fireChooseCell.itemCell.countText.text = UIHelper.GetTextColorByItemColor(TextColType.Red, num.ToString()) + "/" + alchemySpecModel.SpecialMateriaNUM;
|
| | | fireChooseCell.itemCell.countText.text = UIHelper.AppendStringColor(TextColType.Red, num.ToString()) + "/" + alchemySpecModel.SpecialMateriaNUM;
|
| | | }
|
| | | fireChooseCell.addBtn.onClick.AddListener(() => { OnClickSpecAddBtn(alchemySpecModel); });
|
| | | }
|
| | |
| | |
|
| | | if(haveMaterCount >= materialNum)
|
| | | {
|
| | | itemCell.countText.text = UIHelper.GetTextColorByItemColor(TextColType.White,haveMaterCount.ToString()) +"/" + materialNum;
|
| | | itemCell.countText.text = UIHelper.AppendStringColor(TextColType.White,haveMaterCount.ToString()) +"/" + materialNum;
|
| | | }
|
| | | else
|
| | | {
|
| | |
| | | {
|
| | | noEnoughMatID = materialId;
|
| | | }
|
| | | itemCell.countText.text = UIHelper.GetTextColorByItemColor(TextColType.Red, haveMaterCount.ToString()) + "/" + materialNum;
|
| | | itemCell.countText.text = UIHelper.AppendStringColor(TextColType.Red, haveMaterCount.ToString()) + "/" + materialNum;
|
| | | }
|
| | |
|
| | | itemCell.cellBtn.RemoveAllListeners();
|
| | |
| | | if (haveNum >= specModel.SpecialMateriaNUM)
|
| | | {
|
| | | isEnoughSpecMat = true;
|
| | | _addSpecMatItemCell.countText.text = UIHelper.GetTextColorByItemColor(TextColType.Green, haveNum.ToString(),true) + "/" + specModel.SpecialMateriaNUM;
|
| | | _addSpecMatItemCell.countText.text = UIHelper.AppendStringColor(TextColType.Green, haveNum.ToString(),true) + "/" + specModel.SpecialMateriaNUM;
|
| | | }
|
| | | else
|
| | | {
|
| | | isEnoughSpecMat = false;
|
| | | _addSpecMatItemCell.countText.text = UIHelper.GetTextColorByItemColor(TextColType.Red,haveNum.ToString()) + "/" + specModel.SpecialMateriaNUM;
|
| | | _addSpecMatItemCell.countText.text = UIHelper.AppendStringColor(TextColType.Red,haveNum.ToString()) + "/" + specModel.SpecialMateriaNUM;
|
| | | }
|
| | |
|
| | | _addSpecMatItemCell.reducebtn.gameObject.SetActive(true);
|
| | |
| | | _exp = (int)FurnaceModel.addExp;
|
| | | _getExpText.text = Language.Get("BlastFurnace106", _exp);
|
| | | successEffect.Play();
|
| | | string itemName = UIHelper.GetTextColorByItemColor(_chinItemModel.ItemColor, _chinItemModel.ItemName);
|
| | | string itemName = UIHelper.AppendStringColor(_chinItemModel.ItemColor, _chinItemModel.ItemName);
|
| | | _getDrugText.text = Language.Get("BlastFurnace107", itemName);
|
| | |
|
| | | if(FurnaceModel.IsReachMaxStoveLv())
|
| | |
| | | {
|
| | | var config = Config.Instance.Get<BossRebornConfig>(rebornTask.id);
|
| | | var surplusTime = rebornTask.TotalTimes == 0 ? -1 : ((rebornTask.TotalTimes - rebornTask.gotRewardTimes) / rebornTask.SingleTimes);
|
| | | var surplusTimeString = UIHelper.GetTextColorByItemColor(surplusTime == 0 ? TextColType.Red : TextColType.Green,
|
| | | var surplusTimeString = UIHelper.AppendStringColor(surplusTime == 0 ? TextColType.Red : TextColType.Green,
|
| | | surplusTime == -1 ? Language.Get("BossFHLanguage4") : surplusTime.ToString());
|
| | |
|
| | | m_surplusTimes.text = Language.Get("BossFHLanguage3", surplusTimeString);
|
| | |
| | |
|
| | | var config = Config.Instance.Get<BossRebornConfig>(rebornTask.id);
|
| | | var surplusTime = rebornTask.TotalTimes == 0 ? -1 : ((rebornTask.TotalTimes - rebornTask.gotRewardTimes) / rebornTask.SingleTimes);
|
| | | var surplusTimeString = UIHelper.GetTextColorByItemColor(surplusTime == 0 ? TextColType.Red : TextColType.Green,
|
| | | var surplusTimeString = UIHelper.AppendStringColor(surplusTime == 0 ? TextColType.Red : TextColType.Green,
|
| | | surplusTime == -1 ? Language.Get("BossFHLanguage4") : surplusTime.ToString());
|
| | | m_surplusTimes.text = Language.Get("BossFHLanguage3", surplusTimeString);
|
| | |
|
| | |
| | | {
|
| | | string append = string.Format("<a><Word info=item id={0} userdata={4} chatsend=1/>|showitem={0} isbind={1} itemcnt={2} stone={3} userdata={4} suitLv={5} suitCnt={6} place={7} equipwash={8}</a>",
|
| | | strarray[0], strarray[1], strarray[2], strarray[3], strarray[4], strarray[5], strarray[6], strarray[7], strarray[8]);
|
| | | append = UIHelper.GetTextColorByItemColor(cfg.ItemColor, append);
|
| | | append = UIHelper.AppendStringColor(cfg.ItemColor, append);
|
| | | data.richText.Append(append);
|
| | | }
|
| | | catch (Exception e)
|
| | |
| | |
|
| | | if(increaseRate > 0)
|
| | | {
|
| | | string extraAddRate = UIHelper.GetTextColorByItemColor(TextColType.Green,StringUtility.Contact("+", increaseRate, "%"),true);
|
| | | string extraAddRate = UIHelper.AppendStringColor(TextColType.Green,StringUtility.Contact("+", increaseRate, "%"),true);
|
| | | successRateText.text = Language.Get("HallowsWin_Success", StringUtility.Contact(successRate / 100, "%", extraAddRate));
|
| | | }
|
| | | else
|
| | |
| | | itemCell.countText.gameObject.SetActive(true);
|
| | | if (haveCount >= needCount)
|
| | | {
|
| | | itemCell.countText.text = StringUtility.Contact(UIHelper.GetTextColorByItemColor(TextColType.Green, haveCount.ToString()),
|
| | | itemCell.countText.text = StringUtility.Contact(UIHelper.AppendStringColor(TextColType.Green, haveCount.ToString()),
|
| | | "/", needCount);
|
| | | }
|
| | | else
|
| | | {
|
| | | itemCell.countText.text = StringUtility.Contact(UIHelper.GetTextColorByItemColor(TextColType.Red, haveCount.ToString()),
|
| | | itemCell.countText.text = StringUtility.Contact(UIHelper.AppendStringColor(TextColType.Red, haveCount.ToString()),
|
| | | "/", needCount);
|
| | | }
|
| | | break;
|
| | |
| | | var surplusTimes = totalTimes - dungeonRecord.buyTimes;
|
| | | var canBuyTimes = defaultTimes > dungeonRecord.buyTimes || surplusTimes > 0;
|
| | |
|
| | | var surplusTimeDisplay = UIHelper.GetTextColorByItemColor(surplusTimes > 0 ? TextColType.Green : TextColType.Red, surplusTimes.ToString(), true);
|
| | | var surplusTimeDisplay = UIHelper.AppendStringColor(surplusTimes > 0 ? TextColType.Green : TextColType.Red, surplusTimes.ToString(), true);
|
| | |
|
| | | m_TodayBuyTimes.text = Language.Get("TimesBuyLanguage1", surplusTimeDisplay, totalTimes);
|
| | | int nextVipLv = vipModel.GetPrivilegeVipLv((VipPrivilegeType)openTimeConfig.BuyTimesID, totalTimes);
|
| | |
| | | DungeonOpenTimeConfig dungeonOpenTimeModel = Config.Instance.Get<DungeonOpenTimeConfig>(trialMapID);
|
| | | var completedTimes = dailyQuestModel.GetDailyQuestCompletedTimes((int)DailyQuestType.Trial);
|
| | | var totalTimes = dailyQuestModel.GetDailyQuestTotalTimes((int)DailyQuestType.Trial);
|
| | | m_ChallengeTimes.text = Language.Get("TrialChallengeCnt", UIHelper.GetTextColorByItemColor(completedTimes >= totalTimes ?
|
| | | m_ChallengeTimes.text = Language.Get("TrialChallengeCnt", UIHelper.AppendStringColor(completedTimes >= totalTimes ?
|
| | | TextColType.Red : TextColType.LightYellow, completedTimes.ToString(), true), totalTimes);
|
| | | }
|
| | |
|
| | |
| | | DungeonOpenTimeConfig dungeonOpenTimeModel = Config.Instance.Get<DungeonOpenTimeConfig>(mapID);
|
| | | var completedTimes = dailyQuestModel.GetDailyQuestCompletedTimes((int)DailyQuestType.Trial);
|
| | | var totalTimes = dailyQuestModel.GetDailyQuestTotalTimes((int)DailyQuestType.Trial);
|
| | | trialChallengeCntTxt.text = Language.Get("TrialChallengeCnt", UIHelper.GetTextColorByItemColor(completedTimes >= totalTimes ?
|
| | | trialChallengeCntTxt.text = Language.Get("TrialChallengeCnt", UIHelper.AppendStringColor(completedTimes >= totalTimes ?
|
| | | TextColType.Red : TextColType.NavyBrown, completedTimes.ToString(), true), totalTimes);
|
| | | }
|
| | |
|
| | |
| | | }
|
| | | else
|
| | | {
|
| | | m_Time.text = UIHelper.GetTextColorByItemColor(TextColType.Red, Language.Get("XMZZ110"));
|
| | | m_Time.text = UIHelper.AppendStringColor(TextColType.Red, Language.Get("XMZZ110"));
|
| | | }
|
| | | }
|
| | | }
|
| | |
| | | }
|
| | | else
|
| | | {
|
| | | remainTimeText.text = UIHelper.GetTextColorByItemColor(TextColType.Red, Language.Get("XMZZ110"));
|
| | | remainTimeText.text = UIHelper.AppendStringColor(TextColType.Red, Language.Get("XMZZ110"));
|
| | | }
|
| | | }
|
| | |
|
| | |
| | | }
|
| | | else
|
| | | {
|
| | | remainTimeText.text = UIHelper.GetTextColorByItemColor(TextColType.Red,Language.Get("XMZZ110"));
|
| | | remainTimeText.text = UIHelper.AppendStringColor(TextColType.Red,Language.Get("XMZZ110"));
|
| | | }
|
| | |
|
| | | }
|
| | |
| | | }
|
| | | else
|
| | | {
|
| | | remainTimeText.text = UIHelper.GetTextColorByItemColor(TextColType.Red, Language.Get("XMZZ110"));
|
| | | remainTimeText.text = UIHelper.AppendStringColor(TextColType.Red, Language.Get("XMZZ110"));
|
| | | }
|
| | | }
|
| | |
|
| | |
| | | }
|
| | | else
|
| | | {
|
| | | itemCell.countText.text = StringUtility.Contact(UIHelper.GetTextColorByItemColor(TextColType.Red, remainNum.ToString()),
|
| | | itemCell.countText.text = StringUtility.Contact(UIHelper.AppendStringColor(TextColType.Red, remainNum.ToString()),
|
| | | "/" + canBuyCnt.ToString());
|
| | | }
|
| | | }
|
| | |
| | | ulong haveMoney = UIHelper.GetMoneyCnt(1);
|
| | | if (haveMoney >= (ulong)chestsConfig.OpenMoney)
|
| | | {
|
| | | conditionText.text = Language.Get("OpenBoxCostMoney", UIHelper.GetTextColorByItemColor(TextColType.Green, chestsConfig.OpenMoney.ToString()));
|
| | | conditionText.text = Language.Get("OpenBoxCostMoney", UIHelper.AppendStringColor(TextColType.Green, chestsConfig.OpenMoney.ToString()));
|
| | | }
|
| | | else
|
| | | {
|
| | | conditionText.text = Language.Get("OpenBoxCostMoney", UIHelper.GetTextColorByItemColor(TextColType.Red, chestsConfig.OpenMoney.ToString()));
|
| | | conditionText.text = Language.Get("OpenBoxCostMoney", UIHelper.AppendStringColor(TextColType.Red, chestsConfig.OpenMoney.ToString()));
|
| | | }
|
| | | }
|
| | | else
|
| | |
| | | }
|
| | | }
|
| | | string previewExp = StringUtility.Contact(playerPack.decomposeExp,"+",equipAddExpPreview);
|
| | | expNumText.text = StringUtility.Contact(UIHelper.GetTextColorByItemColor(TextColType.Green,previewExp,true),"/"+ deComposeConfig.UpNeedExp);
|
| | | expNumText.text = StringUtility.Contact(UIHelper.AppendStringColor(TextColType.Green,previewExp,true),"/"+ deComposeConfig.UpNeedExp);
|
| | | }
|
| | | else
|
| | | {
|
| | |
| | | {
|
| | | if (offset > 0)
|
| | | {
|
| | | needPoinNum.text = UIHelper.GetTextColorByItemColor(TextColType.Red, StringUtility.Contact(needPoint, Language.Get("KnapS118", offset)));
|
| | | needPoinText.text = UIHelper.GetTextColorByItemColor(TextColType.Red, msg);
|
| | | needPoinNum.text = UIHelper.AppendStringColor(TextColType.Red, StringUtility.Contact(needPoint, Language.Get("KnapS118", offset)));
|
| | | needPoinText.text = UIHelper.AppendStringColor(TextColType.Red, msg);
|
| | | }
|
| | | else
|
| | | {
|
| | |
| | | {
|
| | | if (offset > 0)
|
| | | {
|
| | | needPoinNum.text = UIHelper.GetTextColorByItemColor(TextColType.Red, StringUtility.Contact(needPoint, Language.Get("KnapS118", offset)));
|
| | | needPoinText.text = UIHelper.GetTextColorByItemColor(TextColType.Red, msg);
|
| | | needPoinNum.text = UIHelper.AppendStringColor(TextColType.Red, StringUtility.Contact(needPoint, Language.Get("KnapS118", offset)));
|
| | | needPoinText.text = UIHelper.AppendStringColor(TextColType.Red, msg);
|
| | | }
|
| | | else
|
| | | {
|
| | |
| | | JobNameConfig jobNameConfig = Config.Instance.Get<JobNameConfig>(attrData.itemConfig.JobLimit);
|
| | | if (playerJob >= equipJob)
|
| | | {
|
| | | jobName = UIHelper.GetTextColorByItemColor(TextColType.White, jobNameConfig.name);
|
| | | jobName = UIHelper.AppendStringColor(TextColType.White, jobNameConfig.name);
|
| | | }
|
| | | else
|
| | | {
|
| | | jobName = UIHelper.GetTextColorByItemColor(TextColType.Red, jobNameConfig.name);
|
| | | jobName = UIHelper.AppendStringColor(TextColType.Red, jobNameConfig.name);
|
| | | }
|
| | |
|
| | | }
|
| | | else
|
| | | {
|
| | | jobName = UIHelper.GetTextColorByItemColor(TextColType.White, Language.Get("StoreWin110"));
|
| | | jobName = UIHelper.AppendStringColor(TextColType.White, Language.Get("StoreWin110"));
|
| | | }
|
| | | }
|
| | |
|
| | |
| | | {
|
| | | int runeId = unlockRuneDict[key][0];
|
| | | ItemConfig runeConfig = Config.Instance.Get<ItemConfig>(runeId);
|
| | | string effectDes = StringUtility.Contact(UIHelper.GetTextColorByItemColor(TextColType.Green, runeConfig.ItemName),":",Language.Get(StringUtility.Contact("RuneTypeDesc_",runeConfig.Effect1)));
|
| | | string effectDes = StringUtility.Contact(UIHelper.AppendStringColor(TextColType.Green, runeConfig.ItemName),":",Language.Get(StringUtility.Contact("RuneTypeDesc_",runeConfig.Effect1)));
|
| | | extraInfos.Add(effectDes);
|
| | | }
|
| | | }
|
| | |
| | | if(attrConfig != null)
|
| | | {
|
| | | int value = attrDict[id] * useNum;
|
| | | string valueStr = StringUtility.Contact("+", UIHelper.GetTextColorByItemColor(TextColType.Green, GetProValueTypeStr(attrConfig, value), true));
|
| | | string valueStr = StringUtility.Contact("+", UIHelper.AppendStringColor(TextColType.Green, GetProValueTypeStr(attrConfig, value), true));
|
| | | string attrStr = StringUtility.Contact(attrConfig.Name, valueStr);
|
| | | if(attrSB.Length != 0)
|
| | | {
|
| | |
| | | {
|
| | | if (offset > 0)
|
| | | {
|
| | | needPoinNum.text = UIHelper.GetTextColorByItemColor(TextColType.Red, StringUtility.Contact(needPoint, Language.Get("KnapS118", offset)));
|
| | | needPoinText.text = UIHelper.GetTextColorByItemColor(TextColType.Red, msg);
|
| | | needPoinNum.text = UIHelper.AppendStringColor(TextColType.Red, StringUtility.Contact(needPoint, Language.Get("KnapS118", offset)));
|
| | | needPoinText.text = UIHelper.AppendStringColor(TextColType.Red, msg);
|
| | | }
|
| | | else
|
| | | {
|
| | |
| | | var _realmCfg = Config.Instance.Get<RealmConfig>(_realmLv);
|
| | | if (PlayerDatas.Instance.baseData.realmLevel < _realmLv)
|
| | | {
|
| | | conditionText.text = UIHelper.GetTextColorByItemColor(TextColType.Red, Language.Get("RealmLimit1"));
|
| | | conditionText.text = UIHelper.AppendStringColor(TextColType.Red, Language.Get("RealmLimit1"));
|
| | | if (_realmLv != 0)
|
| | | {
|
| | | conditionValueText.SetSprite(_realmCfg.Img);
|
| | |
| | | if(_haveCount >= needToolCount) |
| | | { |
| | | string s = _haveCount + "/" + needToolCount; |
| | | countText.text = UIHelper.GetTextColorByItemColor(TextColType.White, s); |
| | | countText.text = UIHelper.AppendStringColor(TextColType.White, s); |
| | | } |
| | | else |
| | | { |
| | | string s = UIHelper.GetTextColorByItemColor(TextColType.Red, _haveCount.ToString()) + "/" + UIHelper.GetTextColorByItemColor(TextColType.White, needToolCount.ToString()); |
| | | string s = UIHelper.AppendStringColor(TextColType.Red, _haveCount.ToString()) + "/" + UIHelper.AppendStringColor(TextColType.White, needToolCount.ToString()); |
| | | countText.text = s; |
| | | } |
| | | _needToolCount = needToolCount; |
| | |
| | | var _realmCfg = Config.Instance.Get<RealmConfig>(_realmLv);
|
| | | if (PlayerDatas.Instance.baseData.realmLevel < _realmLv)
|
| | | {
|
| | | conditionText.text = UIHelper.GetTextColorByItemColor(TextColType.Red, Language.Get("RealmLimit1"));
|
| | | conditionText.text = UIHelper.AppendStringColor(TextColType.Red, Language.Get("RealmLimit1"));
|
| | | if (_realmLv != 0)
|
| | | {
|
| | | conditionValueText.SetSprite(_realmCfg.Img);
|
| | |
| | | }
|
| | |
|
| | | int addHour = (itemModel.chinItemModel.EffectValueA1 / 3600)* (int)Mathf.Ceil(_batchUseSlider.value);
|
| | | string addHourStr = UIHelper.GetTextColorByItemColor(TextColType.Green,StringUtility.Contact("+", Language.Get("ItemOverdue103", addHour)),true);
|
| | | string addHourStr = UIHelper.AppendStringColor(TextColType.Green,StringUtility.Contact("+", Language.Get("ItemOverdue103", addHour)),true);
|
| | | s = StringUtility.Contact(s, addHourStr);
|
| | | return s;
|
| | | }
|
| | |
| | | {
|
| | | colorType = text.colorType == RichText.ColorType.Dark ? 0 : 1;
|
| | | }
|
| | | return UIHelper.GetTextColorByItemColor(_itemColor, info, colorType == 1);
|
| | | return UIHelper.AppendStringColor(_itemColor, info, colorType == 1);
|
| | | }
|
| | | }
|
| | |
| | | {
|
| | | colorType = text.colorType == RichText.ColorType.Dark ? 0 : 1;
|
| | | }
|
| | | result = UIHelper.GetTextColorByItemColor(presentColor, result, colorType == 1);
|
| | | result = UIHelper.AppendStringColor(presentColor, result, colorType == 1);
|
| | | }
|
| | | m_StringBuilder.Append(result);
|
| | | }
|
| | |
| | | if (Number != 0) |
| | | { |
| | | string StrNum = Number.ToString() + "/" + SkillConfig.GetSkillTypeIDAndSkillLV(SkillID, 1).ExAttr5; |
| | | _StageTxt.text = UIHelper.GetTextColorByItemColor(0, StrNum); |
| | | _StageTxt.text = UIHelper.AppendStringColor(0, StrNum); |
| | | } |
| | | else |
| | | { |
| | | string StrNum = " <color=#ff2828>" + Number.ToString() + "</color>" + UIHelper.GetTextColorByItemColor(0, "/" + (SkillConfig.GetSkillTypeIDAndSkillLV(SkillID, 1).ExAttr5).ToString()); |
| | | string StrNum = " <color=#ff2828>" + Number.ToString() + "</color>" + UIHelper.AppendStringColor(0, "/" + (SkillConfig.GetSkillTypeIDAndSkillLV(SkillID, 1).ExAttr5).ToString()); |
| | | |
| | | _StageTxt.text = StrNum; |
| | | } |
| | |
| | | {
|
| | | OperationAccumulateRecharge operation = operationBase as OperationAccumulateRecharge;
|
| | | m_Time.text = StringUtility.Contact(Language.Get("ExpActivity_Text1"),
|
| | | UIHelper.GetTextColorByItemColor(TextColType.Green, operation.ToDisplayTime()));
|
| | | UIHelper.AppendStringColor(TextColType.Green, operation.ToDisplayTime()));
|
| | | }
|
| | | }
|
| | |
|
| | |
| | | {
|
| | | if (rushToBuyModel.presentFlashShop == null|| operation == null) return;
|
| | |
|
| | | opreationTimeText.text = StringUtility.Contact(Language.Get("ExpActivity_Text1"),UIHelper.GetTextColorByItemColor(TextColType.Green, operation.ToDisplayTime()));
|
| | | opreationTimeText.text = StringUtility.Contact(Language.Get("ExpActivity_Text1"),UIHelper.AppendStringColor(TextColType.Green, operation.ToDisplayTime()));
|
| | | UpdateMoneyInfo();
|
| | | activityOpenObj.SetActive(true);
|
| | | activityCloseObj.SetActive(false);
|
| | |
| | | {
|
| | | int fullSeverRemain = 0;
|
| | | int sellState = GetSellSate(out fullSeverRemain);
|
| | | string fullSeverRemainStr = fullSeverRemain > 0 ? fullSeverRemain.ToString() : UIHelper.GetTextColorByItemColor(TextColType.Red, fullSeverRemain.ToString());
|
| | | string fullSeverRemainStr = fullSeverRemain > 0 ? fullSeverRemain.ToString() : UIHelper.AppendStringColor(TextColType.Red, fullSeverRemain.ToString());
|
| | | fullServerRemainNum.text = fullSeverRemainStr;
|
| | | switch (sellState)
|
| | | {
|
| | |
| | | m_ItemSlider.value = progress;
|
| | |
|
| | | m_RealmPoint.transform.localPosition = m_RealmPoint.transform.localPosition.SetX(m_ContainerPoint.rect.width * (leftRatio + deltaRatio * 0.5f));
|
| | | m_RealmPoint.text = StringUtility.Contact(UIHelper.GetTextColorByItemColor(realmPoint >= config.NeedPoint ? TextColType.Green : TextColType.Red,
|
| | | m_RealmPoint.text = StringUtility.Contact(UIHelper.AppendStringColor(realmPoint >= config.NeedPoint ? TextColType.Green : TextColType.Red,
|
| | | realmPoint.ToString()), "/", config.NeedPoint);
|
| | |
|
| | | m_OpenRemind.text = realmPoint < config.NeedPoint ? Language.Get("RealmCollecting", config.NeedPoint - realmPoint) : string.Empty;
|
| | |
| | | }
|
| | | else
|
| | | {
|
| | | m_FightPower.text = StringUtility.Contact(UIHelper.GetTextColorByItemColor(TextColType.Green, Language.Get("RolePromoteBetterFight")),
|
| | | UIHelper.GetTextColorByItemColor(fightPower >= config.FightPower ? TextColType.Green : TextColType.Red, fightPower.ToString())
|
| | | m_FightPower.text = StringUtility.Contact(UIHelper.AppendStringColor(TextColType.Green, Language.Get("RolePromoteBetterFight")),
|
| | | UIHelper.AppendStringColor(fightPower >= config.FightPower ? TextColType.Green : TextColType.Red, fightPower.ToString())
|
| | | , "/", config.FightPower);
|
| | | }
|
| | | }
|
| | |
| | | itemCell.countText.gameObject.SetActive(true);
|
| | | if(GetRenameToolNum() > 0)
|
| | | {
|
| | | itemCell.countText.text = StringUtility.Contact(UIHelper.GetTextColorByItemColor(TextColType.Green,GetRenameToolNum().ToString()),
|
| | | itemCell.countText.text = StringUtility.Contact(UIHelper.AppendStringColor(TextColType.Green,GetRenameToolNum().ToString()),
|
| | | "/",1);
|
| | | }
|
| | | else
|
| | | {
|
| | | itemCell.countText.text = StringUtility.Contact(UIHelper.GetTextColorByItemColor(TextColType.Red,0.ToString()),
|
| | | itemCell.countText.text = StringUtility.Contact(UIHelper.AppendStringColor(TextColType.Red,0.ToString()),
|
| | | "/", 1);
|
| | | }
|
| | | itemCell.cellBtn.RemoveAllListeners();
|
| | |
| | | }
|
| | | var _magicEssence = PlayerDatas.Instance.extersion.magicEssence;
|
| | | m_MagicEssenceTxt.text = StringUtility.Contact(_magicEssence >= _cfg.NeedMJ ?
|
| | | UIHelper.GetTextColorByItemColor(TextColType.Green, _magicEssence.ToString()) :
|
| | | UIHelper.GetTextColorByItemColor(TextColType.Red, _magicEssence.ToString()), "/", _cfg.NeedMJ);
|
| | | UIHelper.AppendStringColor(TextColType.Green, _magicEssence.ToString()) :
|
| | | UIHelper.AppendStringColor(TextColType.Red, _magicEssence.ToString()), "/", _cfg.NeedMJ);
|
| | | }
|
| | | }
|
| | | void RefreshRuneCompose()
|
| | |
| | | m_ComposeRedpoint.redpointId = _redpointTypeKey * 100 + model.presentSelectComposeRune;
|
| | | var _magicEssence = PlayerDatas.Instance.extersion.magicEssence;
|
| | | m_MagicEssenceTxt.text = StringUtility.Contact(_magicEssence >= _cfg.NeedMJ ?
|
| | | UIHelper.GetTextColorByItemColor(TextColType.Green, _magicEssence.ToString()) :
|
| | | UIHelper.GetTextColorByItemColor(TextColType.Red, _magicEssence.ToString()), "/", _cfg.NeedMJ);
|
| | | UIHelper.AppendStringColor(TextColType.Green, _magicEssence.ToString()) :
|
| | | UIHelper.AppendStringColor(TextColType.Red, _magicEssence.ToString()), "/", _cfg.NeedMJ);
|
| | |
|
| | | ItemConfig _itemCfg = Config.Instance.Get<ItemConfig>(_cfg.NeedItem[0]);
|
| | | m_Rune1Img.SetSprite(_itemCfg.IconKey);
|
| | | RuneData _rune1 = null;
|
| | | var _runeCnt = runeModel.GetMaxLevelRuneCnt(_cfg.NeedItem[0], out _rune1);
|
| | | m_Rune1NumTxt.text = StringUtility.Contact(_runeCnt > 0 ?
|
| | | UIHelper.GetTextColorByItemColor(TextColType.White, _runeCnt.ToString()) :
|
| | | UIHelper.GetTextColorByItemColor(TextColType.Red, _runeCnt.ToString()), "/", 1);
|
| | | UIHelper.AppendStringColor(TextColType.White, _runeCnt.ToString()) :
|
| | | UIHelper.AppendStringColor(TextColType.Red, _runeCnt.ToString()), "/", 1);
|
| | | m_Rune1NameTxt.text = StringUtility.Contact(_itemCfg.ItemName, " Lv.", _rune1 == null ? 1 : _rune1.lv);
|
| | | m_Rune1NameTxt.color = UIHelper.GetUIColor(_itemCfg.ItemColor, true);
|
| | |
|
| | |
| | | RuneData _rune2 = null;
|
| | | _runeCnt = runeModel.GetMaxLevelRuneCnt(_cfg.NeedItem[1], out _rune2);
|
| | | m_Rune2NumTxt.text = StringUtility.Contact(_runeCnt > 0 ?
|
| | | UIHelper.GetTextColorByItemColor(TextColType.White, _runeCnt.ToString()) :
|
| | | UIHelper.GetTextColorByItemColor(TextColType.Red, _runeCnt.ToString()), "/", 1);
|
| | | UIHelper.AppendStringColor(TextColType.White, _runeCnt.ToString()) :
|
| | | UIHelper.AppendStringColor(TextColType.Red, _runeCnt.ToString()), "/", 1);
|
| | | m_Rune2NameTxt.text = StringUtility.Contact(_itemCfg.ItemName, " Lv.", _rune2 == null ? 1 : _rune2.lv);
|
| | | m_Rune2NameTxt.color = UIHelper.GetUIColor(_itemCfg.ItemColor, true);
|
| | |
|
| | |
| | | m_RuneLevelUpBtn.gameObject.SetActive(!_isRuneMaxLv);
|
| | | //m_ContainerLevelUp.gameObject.SetActive(!_isRuneMaxLv);
|
| | | m_ContaienrMaxLevel.gameObject.SetActive(_isRuneMaxLv);
|
| | | runeLevelUpItemNum.text = StringUtility.Contact(UIHelper.GetTextColorByItemColor(
|
| | | runeLevelUpItemNum.text = StringUtility.Contact(UIHelper.AppendStringColor(
|
| | | model.RuneSplinters >= _levelUpExp ? TextColType.Green : TextColType.Red
|
| | | , model.RuneSplinters.ToString(), true), "/", _levelUpExp);
|
| | | }
|
| | |
| | | |
| | | _describeText.alignment = TextAnchor.UpperCenter; |
| | | _describeText.text = StringUtility.Contact(itemPathModel.extraInfos[0], "\n", |
| | | UIHelper.GetTextColorByItemColor(TextColType.Blue, itemPathModel.extraInfos[1])); |
| | | UIHelper.AppendStringColor(TextColType.Blue, itemPathModel.extraInfos[1])); |
| | | |
| | | } |
| | | |
| | |
| | | m_RuneBtn.onClick.RemoveAllListeners();
|
| | | if (_itemCfg != null)
|
| | | {
|
| | | m_RuneName.text = UIHelper.GetTextColorByItemColor(_itemCfg.ItemColor, _itemCfg.ItemName + "lv.1");
|
| | | m_RuneName.text = UIHelper.AppendStringColor(_itemCfg.ItemColor, _itemCfg.ItemName + "lv.1");
|
| | | m_RuneIcon.SetSprite(_itemCfg.IconKey);
|
| | | m_RuneBtn.onClick.AddListener(()=>
|
| | | {
|
| | |
| | |
|
| | | m_Rune.Display(config.RuneDrop);
|
| | | var itemConfig = Config.Instance.Get<ItemConfig>(config.RuneDrop);
|
| | | m_RuneDrop.text = Language.Get("RuneTower13", UIHelper.GetTextColorByItemColor(itemConfig.ItemColor, itemConfig.ItemName));
|
| | | m_RuneDrop.text = Language.Get("RuneTower13", UIHelper.AppendStringColor(itemConfig.ItemColor, itemConfig.ItemName));
|
| | | }
|
| | | else if (config.Fixed == 1)
|
| | | {
|
| | |
| | |
|
| | | m_Rune.Display(config.RuneDrop);
|
| | | var itemConfig = Config.Instance.Get<ItemConfig>(config.RuneDrop);
|
| | | m_RuneDrop.text = Language.Get("RuneTower23", UIHelper.GetTextColorByItemColor(itemConfig.ItemColor, itemConfig.ItemName));
|
| | | m_RuneDrop.text = Language.Get("RuneTower23", UIHelper.AppendStringColor(itemConfig.ItemColor, itemConfig.ItemName));
|
| | | }
|
| | | else if (config.UnLockHole > 0)
|
| | | {
|
| | |
| | | var requireSeries = skillConfig.RequireTalentSeries();
|
| | | var point = model.GetSeriesPoint(talentConfig.type, requireSeries);
|
| | | var requireDisplay = StringUtility.Contact(point, "/", requireSeriesPoint);
|
| | | requireDisplay = UIHelper.GetTextColorByItemColor(point >= requireSeriesPoint ?
|
| | | requireDisplay = UIHelper.AppendStringColor(point >= requireSeriesPoint ?
|
| | | TextColType.Green : TextColType.Red, requireDisplay);
|
| | | var seriesDisplay = Language.Get("TalentSeriesCondition", Language.Get(StringUtility.Contact("TalentSeries_", requireSeries)));
|
| | | m_SelectConditions[index].text = StringUtility.Contact(seriesDisplay, requireDisplay);
|
| | |
| | | var requirePropertyValue = skillConfig.RequirePropertyValue();
|
| | | var propertyValue = UIHelper.GetPropertyMapPlayerData((AttrEnum)requireProperty);
|
| | | var requireDisplay = StringUtility.Contact(propertyValue, "/", requirePropertyValue);
|
| | | requireDisplay = UIHelper.GetTextColorByItemColor(propertyValue >= requirePropertyValue ?
|
| | | requireDisplay = UIHelper.AppendStringColor(propertyValue >= requirePropertyValue ?
|
| | | TextColType.Green : TextColType.Red, requireDisplay);
|
| | | var propertyConfig = Config.Instance.Get<PlayerPropertyConfig>(requireProperty);
|
| | | var propertyDisplay = Language.Get("TalentPropertyCondition", propertyConfig.Name);
|
| | |
| | | var learnSkillConfig = Config.Instance.Get<SkillConfig>(skillConfig.LearnSkillReq);
|
| | | m_SelectConditions[index].gameObject.SetActive(true);
|
| | | var requireDisplay = StringUtility.Contact(learnSkillConfig.SkillName, " ", learnTalent.level, "/", skillConfig.LearnSkillLV);
|
| | | requireDisplay = UIHelper.GetTextColorByItemColor(learnTalent.level >= skillConfig.LearnSkillLV ?
|
| | | requireDisplay = UIHelper.AppendStringColor(learnTalent.level >= skillConfig.LearnSkillLV ?
|
| | | TextColType.Green : TextColType.Red, requireDisplay);
|
| | | m_SelectConditions[index].text = StringUtility.Contact(Language.Get("TalentPreSkillCondition"), requireDisplay);
|
| | | index++;
|
| | |
| | | }
|
| | | else
|
| | | {
|
| | | shopItemCell.itemCell.countText.text = StringUtility.Contact(UIHelper.GetTextColorByItemColor(TextColType.Red, remainNum.ToString()),
|
| | | shopItemCell.itemCell.countText.text = StringUtility.Contact(UIHelper.AppendStringColor(TextColType.Red, remainNum.ToString()),
|
| | | "/" + canBuyCnt.ToString());
|
| | | shopItemCell.sellImage.gameObject.SetActive(true);
|
| | | shopItemCell.stateImage.gameObject.SetActive(false);
|
| | |
| | | ulong haveMoney = UIHelper.GetMoneyCnt(1);
|
| | | if (haveMoney >= (ulong)chestsConfig.OpenMoney)
|
| | | {
|
| | | conditionText.text = Language.Get("OpenBoxCostMoney", UIHelper.GetTextColorByItemColor(TextColType.Green, chestsConfig.OpenMoney.ToString()));
|
| | | conditionText.text = Language.Get("OpenBoxCostMoney", UIHelper.AppendStringColor(TextColType.Green, chestsConfig.OpenMoney.ToString()));
|
| | | }
|
| | | else
|
| | | {
|
| | | conditionText.text = Language.Get("OpenBoxCostMoney", UIHelper.GetTextColorByItemColor(TextColType.Red, chestsConfig.OpenMoney.ToString()));
|
| | | conditionText.text = Language.Get("OpenBoxCostMoney", UIHelper.AppendStringColor(TextColType.Red, chestsConfig.OpenMoney.ToString()));
|
| | | }
|
| | | }
|
| | | else
|
| | |
| | |
|
| | | if (!m_storeModel.MoneyIsEnough(buyItem.storeConfig.MoneyType, _price))
|
| | | {
|
| | | buyPriceText.text = UIHelper.GetTextColorByItemColor(TextColType.Red, _price.ToString());
|
| | | buyPriceText.text = UIHelper.AppendStringColor(TextColType.Red, _price.ToString());
|
| | | }
|
| | | else
|
| | | {
|
| | | buyPriceText.text = UIHelper.GetTextColorByItemColor(TextColType.Green, _price.ToString());
|
| | | buyPriceText.text = UIHelper.AppendStringColor(TextColType.Green, _price.ToString());
|
| | | }
|
| | |
|
| | | if (_price <= 0)
|
| | |
| | | {
|
| | | if (offset > 0)
|
| | | {
|
| | | needPoinNum.text = UIHelper.GetTextColorByItemColor(TextColType.Red, StringUtility.Contact(needPoint, Language.Get("KnapS118", offset)));
|
| | | needPoinText.text = UIHelper.GetTextColorByItemColor(TextColType.Red, msg);
|
| | | needPoinNum.text = UIHelper.AppendStringColor(TextColType.Red, StringUtility.Contact(needPoint, Language.Get("KnapS118", offset)));
|
| | | needPoinText.text = UIHelper.AppendStringColor(TextColType.Red, msg);
|
| | | }
|
| | | else
|
| | | {
|
| | |
| | |
|
| | | if (!m_storeModel.MoneyIsEnough(buyItem.storeConfig.MoneyType, _price))
|
| | | {
|
| | | buyPriceText.text = UIHelper.GetTextColorByItemColor(TextColType.Red, _price.ToString());
|
| | | buyPriceText.text = UIHelper.AppendStringColor(TextColType.Red, _price.ToString());
|
| | | }
|
| | | else
|
| | | {
|
| | | buyPriceText.text = UIHelper.GetTextColorByItemColor(TextColType.Green, _price.ToString());
|
| | | buyPriceText.text = UIHelper.AppendStringColor(TextColType.Green, _price.ToString());
|
| | | }
|
| | |
|
| | | if (_price <= 0)
|
| | |
| | | {
|
| | | if (offset > 0)
|
| | | {
|
| | | needPoinNum.text = UIHelper.GetTextColorByItemColor(TextColType.Red, StringUtility.Contact(needPoint, Language.Get("KnapS118", offset)));
|
| | | needPoinText.text = UIHelper.GetTextColorByItemColor(TextColType.Red, msg);
|
| | | needPoinNum.text = UIHelper.AppendStringColor(TextColType.Red, StringUtility.Contact(needPoint, Language.Get("KnapS118", offset)));
|
| | | needPoinText.text = UIHelper.AppendStringColor(TextColType.Red, msg);
|
| | | }
|
| | | else
|
| | | {
|
| | |
| | |
|
| | | if (!m_storeModel.MoneyIsEnough(buyItem.storeConfig.MoneyType, _price))
|
| | | {
|
| | | buyPriceText.text = UIHelper.GetTextColorByItemColor(TextColType.Red, _price.ToString());
|
| | | buyPriceText.text = UIHelper.AppendStringColor(TextColType.Red, _price.ToString());
|
| | | }
|
| | | else
|
| | | {
|
| | | buyPriceText.text = UIHelper.GetTextColorByItemColor(TextColType.Green, _price.ToString());
|
| | | buyPriceText.text = UIHelper.AppendStringColor(TextColType.Green, _price.ToString());
|
| | | }
|
| | |
|
| | |
|
| | |
| | |
|
| | | if (!m_storeModel.MoneyIsEnough(buyItem.storeConfig.MoneyType, _price))
|
| | | {
|
| | | buyPriceText.text = UIHelper.GetTextColorByItemColor(TextColType.Red, _price.ToString());
|
| | | buyPriceText.text = UIHelper.AppendStringColor(TextColType.Red, _price.ToString());
|
| | | }
|
| | | else
|
| | | {
|
| | | buyPriceText.text = UIHelper.GetTextColorByItemColor(TextColType.Green, _price.ToString());
|
| | | buyPriceText.text = UIHelper.AppendStringColor(TextColType.Green, _price.ToString());
|
| | | }
|
| | |
|
| | | if (_price <= 0)
|
| | |
| | |
|
| | | if (!m_storeModel.MoneyIsEnough(buyItem.storeConfig.MoneyType, _price))
|
| | | {
|
| | | buyPriceText.text = UIHelper.GetTextColorByItemColor(TextColType.Red, _price.ToString());
|
| | | buyPriceText.text = UIHelper.AppendStringColor(TextColType.Red, _price.ToString());
|
| | | }
|
| | | else
|
| | | {
|
| | | buyPriceText.text = UIHelper.GetTextColorByItemColor(TextColType.Green, _price.ToString());
|
| | | buyPriceText.text = UIHelper.AppendStringColor(TextColType.Green, _price.ToString());
|
| | | }
|
| | |
|
| | | if (_price <= 0)
|
| | |
| | | var _realmCfg = Config.Instance.Get<RealmConfig>(_realmLv);
|
| | | if (PlayerDatas.Instance.baseData.realmLevel < _realmLv)
|
| | | {
|
| | | conditionText.text = UIHelper.GetTextColorByItemColor(TextColType.Red, Language.Get("RealmLimit1"));
|
| | | conditionText.text = UIHelper.AppendStringColor(TextColType.Red, Language.Get("RealmLimit1"));
|
| | | if (_realmLv != 0)
|
| | | {
|
| | | conditionValueText.SetSprite(_realmCfg.Img);
|
| | |
| | |
|
| | | if (!m_storeModel.MoneyIsEnough(buyItem.storeConfig.MoneyType, _price))
|
| | | {
|
| | | buyPriceText.text = UIHelper.GetTextColorByItemColor(TextColType.Red, _price.ToString());
|
| | | buyPriceText.text = UIHelper.AppendStringColor(TextColType.Red, _price.ToString());
|
| | | }
|
| | | else
|
| | | {
|
| | | buyPriceText.text = UIHelper.GetTextColorByItemColor(TextColType.Green, _price.ToString());
|
| | | buyPriceText.text = UIHelper.AppendStringColor(TextColType.Green, _price.ToString());
|
| | | }
|
| | |
|
| | | if (_price <= 0)
|
| | |
| | | {
|
| | | case 7:
|
| | | int willRefreshTime = GetWillRefreshTime();
|
| | | return Language.Get(resetTimeDict[type],UIHelper.GetTextColorByItemColor(TextColType.Green, TimeUtility.SecondsToHMS(willRefreshTime),true));
|
| | | return Language.Get(resetTimeDict[type],UIHelper.AppendStringColor(TextColType.Green, TimeUtility.SecondsToHMS(willRefreshTime),true));
|
| | | //if(willRefreshTime == 0)
|
| | | //{
|
| | | // return Language.Get("StoreWin201");
|
| | |
| | | }
|
| | | else
|
| | | {
|
| | | shopItemCell.itemCell.countText.text = StringUtility.Contact(UIHelper.GetTextColorByItemColor(TextColType.Red, remainNum.ToString()),
|
| | | shopItemCell.itemCell.countText.text = StringUtility.Contact(UIHelper.AppendStringColor(TextColType.Red, remainNum.ToString()),
|
| | | "/" + canBuyCnt.ToString());
|
| | | shopItemCell.sellImage.gameObject.SetActive(true);
|
| | | shopItemCell.stateImage.gameObject.SetActive(false);
|
| | |
| | | }
|
| | | else
|
| | | {
|
| | | shopItemCell.itemCell.countText.text = StringUtility.Contact(UIHelper.GetTextColorByItemColor(TextColType.Red, remainNum.ToString()),
|
| | | shopItemCell.itemCell.countText.text = StringUtility.Contact(UIHelper.AppendStringColor(TextColType.Red, remainNum.ToString()),
|
| | | "/" + canBuyCnt.ToString());
|
| | | shopItemCell.sellImage.gameObject.SetActive(true);
|
| | | shopItemCell.buyBtn.gameObject.SetActive(false);
|
| | |
| | | }
|
| | | break;
|
| | | }
|
| | | nameText.text = UIHelper.GetTextColorByItemColor(itemModel.chinItemModel.ItemColor, itemModel.chinItemModel.ItemName, true);
|
| | | nameText.text = UIHelper.AppendStringColor(itemModel.chinItemModel.ItemColor, itemModel.chinItemModel.ItemName, true);
|
| | | }
|
| | | else
|
| | | {
|
| | |
| | | int haveCount = playerPack.GetItemCountByID(PackType.rptItem, _equipSuitMatModel.CostItemID[materIndex]);
|
| | | if (haveCount >= _equipSuitMatModel.CostItemCnt[materIndex])
|
| | | {
|
| | | materCount.text = StringUtility.Contact(UIHelper.GetTextColorByItemColor(TextColType.Green, haveCount.ToString(), true), "/", _equipSuitMatModel.CostItemCnt[materIndex]);
|
| | | materCount.text = StringUtility.Contact(UIHelper.AppendStringColor(TextColType.Green, haveCount.ToString(), true), "/", _equipSuitMatModel.CostItemCnt[materIndex]);
|
| | | }
|
| | | else
|
| | | {
|
| | | materCount.text = StringUtility.Contact(UIHelper.GetTextColorByItemColor(TextColType.Red, haveCount.ToString()), "/", _equipSuitMatModel.CostItemCnt[materIndex]);
|
| | | materCount.text = StringUtility.Contact(UIHelper.AppendStringColor(TextColType.Red, haveCount.ToString()), "/", _equipSuitMatModel.CostItemCnt[materIndex]);
|
| | | }
|
| | | }
|
| | | else
|
| | |
| | | nameText.gameObject.SetActive(true);
|
| | | washLevelText.gameObject.SetActive(true);
|
| | | noEquipGo.SetActive(false);
|
| | | nameText.text = UIHelper.GetTextColorByItemColor(itemModel.chinItemModel.ItemColor, itemModel.chinItemModel.ItemName, true);
|
| | | nameText.text = UIHelper.AppendStringColor(itemModel.chinItemModel.ItemColor, itemModel.chinItemModel.ItemName, true);
|
| | | //pdr ToDo
|
| | | itemCell.Init(itemModel);
|
| | | washLevelText.text = equipWashModel.GetCurWashLvStr(washPro, washModel);
|
| | |
| | | { |
| | | ItemConfig cfg = Config.Instance.Get<ItemConfig>(_itemModel.itemInfo.ItemID); |
| | | m_EquipNameTxt.gameObject.SetActive(true); |
| | | m_EquipNameTxt.text = UIHelper.GetTextColorByItemColor(cfg.ItemColor, cfg.ItemName, true); |
| | | m_EquipNameTxt.text = UIHelper.AppendStringColor(cfg.ItemColor, cfg.ItemName, true); |
| | | m_ItemCell.gameObject.SetActive(true); |
| | | m_ItemCell.Init(_itemModel); |
| | | m_ContentTxt.gameObject.SetActive(false); |
| | |
| | | gemUpCost = model.GemLevelUpCost(cfg.EffectValueB1, model.GetSingleGemPrice(cfg.EffectValueA1));
|
| | | if (PlayerDatas.Instance.baseData.Gold < gemUpCost)
|
| | | {
|
| | | _gemLevelUpCost.text = UIHelper.GetTextColorByItemColor(TextColType.Red, gemUpCost.ToString(), true);
|
| | | _gemLevelUpCost.text = UIHelper.AppendStringColor(TextColType.Red, gemUpCost.ToString(), true);
|
| | | }
|
| | | else
|
| | | {
|
| | | _gemLevelUpCost.text = UIHelper.GetTextColorByItemColor(TextColType.NavyBrown, gemUpCost.ToString());
|
| | | _gemLevelUpCost.text = UIHelper.AppendStringColor(TextColType.NavyBrown, gemUpCost.ToString());
|
| | | }
|
| | | OnUpdateGemCount();
|
| | | _gemLevelUpNextIcon.SetSprite(next.IconKey);
|
| | |
| | | if (IudetDogzEquipPlus != null && IudetDogzEquipPlus[0] > 0)
|
| | | {
|
| | | string str= itemConfig.ItemName + " +" + IudetDogzEquipPlus[0];
|
| | | m_Item_Text.text = UIHelper.GetTextColorByItemColor(itemConfig.ItemColor, str, true);
|
| | | m_Item_Text.text = UIHelper.AppendStringColor(itemConfig.ItemColor, str, true);
|
| | | }
|
| | | else
|
| | | {
|
| | | string str = itemConfig.ItemName;
|
| | | m_Item_Text.text = UIHelper.GetTextColorByItemColor(itemConfig.ItemColor, str, true);
|
| | | m_Item_Text.text = UIHelper.AppendStringColor(itemConfig.ItemColor, str, true);
|
| | | }
|
| | | if (locationMarker == currentlySelected)
|
| | | {
|
| | |
| | | case 0:
|
| | | case 1:
|
| | | str = _Item.ItemName + " +" + StrengthenTheCeiling(_itemPM.levelMax, _equipmentLevel);
|
| | | _nameText.text = UIHelper.GetTextColorByItemColor(_Item.ItemColor, str, true);
|
| | | _nameText.text = UIHelper.AppendStringColor(_Item.ItemColor, str, true);
|
| | | break;
|
| | | case 2:
|
| | |
|
| | | str = _Item.ItemName + " +" + StrengthenTheCeiling(_itemPM.levelMax, _equipmentLevel);
|
| | | _nameText.text = UIHelper.GetTextColorByItemColor(_Item.ItemColor, str, true);
|
| | | _nameText.text = UIHelper.AppendStringColor(_Item.ItemColor, str, true);
|
| | | break;
|
| | | case 3:
|
| | |
|
| | | str = _Item.ItemName + " +" + StrengthenTheCeiling(_itemPM.levelMax, _equipmentLevel);
|
| | | _nameText.text = UIHelper.GetTextColorByItemColor(_Item.ItemColor, str, true);
|
| | | _nameText.text = UIHelper.AppendStringColor(_Item.ItemColor, str, true);
|
| | | break;
|
| | | case 4:
|
| | |
|
| | | str = _Item.ItemName + " +" + StrengthenTheCeiling(_itemPM.levelMax, _equipmentLevel);
|
| | | _nameText.text = UIHelper.GetTextColorByItemColor(_Item.ItemColor, str, true);
|
| | | _nameText.text = UIHelper.AppendStringColor(_Item.ItemColor, str, true);
|
| | | break;
|
| | | case 5:
|
| | | str = _Item.ItemName + " +" + StrengthenTheCeiling(_itemPM.levelMax, _equipmentLevel);
|
| | | _nameText.text = UIHelper.GetTextColorByItemColor(_Item.ItemColor, str, true);
|
| | | _nameText.text = UIHelper.AppendStringColor(_Item.ItemColor, str, true);
|
| | | break;
|
| | | case 6:
|
| | | str = _Item.ItemName + " +" + StrengthenTheCeiling(_itemPM.levelMax, _equipmentLevel);
|
| | | _nameText.text = UIHelper.GetTextColorByItemColor(_Item.ItemColor, str, true);
|
| | | _nameText.text = UIHelper.AppendStringColor(_Item.ItemColor, str, true);
|
| | | break;
|
| | | default:
|
| | | break;
|
| | |
| | | case 0:
|
| | | case 1:
|
| | | str = _Item.ItemName + " +" + StrengthenTheCeiling(_itemPM.levelMax, strengthengmodel._EqInfo[_equipmentLevel].EquipPartStarLV);
|
| | | return UIHelper.GetTextColorByItemColor(_Item.ItemColor, str, true);
|
| | | return UIHelper.AppendStringColor(_Item.ItemColor, str, true);
|
| | | case 2:
|
| | | str = _Item.ItemName + " +" + StrengthenTheCeiling(_itemPM.levelMax, strengthengmodel._EqInfo[_equipmentLevel].EquipPartStarLV);
|
| | | return UIHelper.GetTextColorByItemColor(_Item.ItemColor, str, true);
|
| | | return UIHelper.AppendStringColor(_Item.ItemColor, str, true);
|
| | | case 3:
|
| | | str = _Item.ItemName + " +" + StrengthenTheCeiling(_itemPM.levelMax, strengthengmodel._EqInfo[_equipmentLevel].EquipPartStarLV);
|
| | | return UIHelper.GetTextColorByItemColor(_Item.ItemColor, str, true);
|
| | | return UIHelper.AppendStringColor(_Item.ItemColor, str, true);
|
| | | case 4:
|
| | | str = _Item.ItemName + " +" + StrengthenTheCeiling(_itemPM.levelMax, strengthengmodel._EqInfo[_equipmentLevel].EquipPartStarLV);
|
| | | return UIHelper.GetTextColorByItemColor(_Item.ItemColor, str, true);
|
| | | return UIHelper.AppendStringColor(_Item.ItemColor, str, true);
|
| | | case 5:
|
| | | str = _Item.ItemName + " +" + StrengthenTheCeiling(_itemPM.levelMax, strengthengmodel._EqInfo[_equipmentLevel].EquipPartStarLV);
|
| | | return UIHelper.GetTextColorByItemColor(_Item.ItemColor, str, true);
|
| | | return UIHelper.AppendStringColor(_Item.ItemColor, str, true);
|
| | | case 6:
|
| | | str = _Item.ItemName + " +" + StrengthenTheCeiling(_itemPM.levelMax, strengthengmodel._EqInfo[_equipmentLevel].EquipPartStarLV);
|
| | | return UIHelper.GetTextColorByItemColor(_Item.ItemColor, str, true);
|
| | | return UIHelper.AppendStringColor(_Item.ItemColor, str, true);
|
| | | default:
|
| | | return str;
|
| | | }
|
| | |
| | | if(itemModel == null)
|
| | | {
|
| | | itemBaisc.gameObject.SetActive(false);
|
| | | washDesText.text = UIHelper.GetTextColorByItemColor(TextColType.Red, Language.Get("EquipSuitPanel_IsPutOnText_1"));
|
| | | washDesText.text = UIHelper.AppendStringColor(TextColType.Red, Language.Get("EquipSuitPanel_IsPutOnText_1"));
|
| | | }
|
| | | else
|
| | | {
|
| | |
| | | {
|
| | | if (curLv >= masterLv)
|
| | | {
|
| | | washDesText.text = Language.Get("EquipWash119", StringUtility.Contact(UIHelper.GetTextColorByItemColor(TextColType.Green, curLv.ToString()), "/", masterLv));
|
| | | washDesText.text = Language.Get("EquipWash119", StringUtility.Contact(UIHelper.AppendStringColor(TextColType.Green, curLv.ToString()), "/", masterLv));
|
| | | }
|
| | | else
|
| | | {
|
| | | washDesText.text = Language.Get("EquipWash119", StringUtility.Contact(UIHelper.GetTextColorByItemColor(TextColType.Red, curLv.ToString()), "/", masterLv));
|
| | | washDesText.text = Language.Get("EquipWash119", StringUtility.Contact(UIHelper.AppendStringColor(TextColType.Red, curLv.ToString()), "/", masterLv));
|
| | | }
|
| | | }
|
| | | else
|
| | | {
|
| | | washDesText.text = Language.Get("EquipWash119", StringUtility.Contact(UIHelper.GetTextColorByItemColor(TextColType.Green, curLv.ToString())));
|
| | | washDesText.text = Language.Get("EquipWash119", StringUtility.Contact(UIHelper.AppendStringColor(TextColType.Green, curLv.ToString())));
|
| | | }
|
| | | }
|
| | |
|
| | |
| | | }
|
| | | if (curMasterCnt >= 2)
|
| | | {
|
| | | washMasterCondText.text = StringUtility.Contact(Language.Get("EquipWash112", p_nextSpecModel.specConfig.levelNeed), ":", UIHelper.GetTextColorByItemColor(TextColType.Green, curMasterCnt.ToString()), "/", 2);
|
| | | washMasterCondText.text = StringUtility.Contact(Language.Get("EquipWash112", p_nextSpecModel.specConfig.levelNeed), ":", UIHelper.AppendStringColor(TextColType.Green, curMasterCnt.ToString()), "/", 2);
|
| | | }
|
| | | else
|
| | | {
|
| | | washMasterCondText.text = StringUtility.Contact(Language.Get("EquipWash112", p_nextSpecModel.specConfig.levelNeed), ":", UIHelper.GetTextColorByItemColor(TextColType.Red, curMasterCnt.ToString()), "/", 2);
|
| | | washMasterCondText.text = StringUtility.Contact(Language.Get("EquipWash112", p_nextSpecModel.specConfig.levelNeed), ":", UIHelper.AppendStringColor(TextColType.Red, curMasterCnt.ToString()), "/", 2);
|
| | | }
|
| | | }
|
| | | else
|
| | |
| | | }
|
| | | if (curMasterCnt >= 5)
|
| | | {
|
| | | washMasterCondText.text = StringUtility.Contact(Language.Get("EquipWash112", p_nextSpecModel.specConfig.levelNeed), ":", UIHelper.GetTextColorByItemColor(TextColType.Green, curMasterCnt.ToString()), "/", 5);
|
| | | washMasterCondText.text = StringUtility.Contact(Language.Get("EquipWash112", p_nextSpecModel.specConfig.levelNeed), ":", UIHelper.AppendStringColor(TextColType.Green, curMasterCnt.ToString()), "/", 5);
|
| | | }
|
| | | else
|
| | | {
|
| | | washMasterCondText.text = StringUtility.Contact(Language.Get("EquipWash112", p_nextSpecModel.specConfig.levelNeed), ":", UIHelper.GetTextColorByItemColor(TextColType.Red, curMasterCnt.ToString()), "/", 5);
|
| | | washMasterCondText.text = StringUtility.Contact(Language.Get("EquipWash112", p_nextSpecModel.specConfig.levelNeed), ":", UIHelper.AppendStringColor(TextColType.Red, curMasterCnt.ToString()), "/", 5);
|
| | | }
|
| | | }
|
| | | else
|
| | |
| | | }
|
| | | if(curMasterCnt >= 3)
|
| | | {
|
| | | washMasterCondText.text = StringUtility.Contact(Language.Get("EquipWash112", p_nextSpecModel.specConfig.levelNeed), ":", UIHelper.GetTextColorByItemColor(TextColType.Green,curMasterCnt.ToString()), "/", 3);
|
| | | washMasterCondText.text = StringUtility.Contact(Language.Get("EquipWash112", p_nextSpecModel.specConfig.levelNeed), ":", UIHelper.AppendStringColor(TextColType.Green,curMasterCnt.ToString()), "/", 3);
|
| | | }
|
| | | else
|
| | | {
|
| | | washMasterCondText.text = StringUtility.Contact(Language.Get("EquipWash112", p_nextSpecModel.specConfig.levelNeed), ":", UIHelper.GetTextColorByItemColor(TextColType.Red, curMasterCnt.ToString()), "/", 3);
|
| | | washMasterCondText.text = StringUtility.Contact(Language.Get("EquipWash112", p_nextSpecModel.specConfig.levelNeed), ":", UIHelper.AppendStringColor(TextColType.Red, curMasterCnt.ToString()), "/", 3);
|
| | | }
|
| | |
|
| | | }
|
| | |
| | | _costMatCell.countText.gameObject.SetActive(true);
|
| | | int bagItemCount = singlePack.GetItemCountByID(_tagWashModel.costItem);
|
| | | if (bagItemCount >= _tagWashModel.costCount)
|
| | | _costMatCell.countText.text = UIHelper.GetTextColorByItemColor(TextColType.Green, bagItemCount.ToString(),true) + "/" + _tagWashModel.costCount;
|
| | | _costMatCell.countText.text = UIHelper.AppendStringColor(TextColType.Green, bagItemCount.ToString(),true) + "/" + _tagWashModel.costCount;
|
| | | else
|
| | | _costMatCell.countText.text = UIHelper.GetTextColorByItemColor(TextColType.Red, bagItemCount.ToString()) + "/" + _tagWashModel.costCount;
|
| | | _costMatCell.countText.text = UIHelper.AppendStringColor(TextColType.Red, bagItemCount.ToString()) + "/" + _tagWashModel.costCount;
|
| | |
|
| | | }
|
| | |
|
| | |
| | | int color = modelInterface.GetItemQuality(model.itemInfo.ItemID, model.useDataDict);
|
| | | _WingButton.IconBG.SetItemBackGround(color);
|
| | | _WingButton.Icon.SetSprite(tagItem.IconKey);
|
| | | _WingButton.WingsText.text = UIHelper.GetTextColorByItemColor((TextColType)color, tagItem.ItemName, true);
|
| | | _WingButton.WingsText.text = UIHelper.AppendStringColor((TextColType)color, tagItem.ItemName, true);
|
| | | int _currentRefining = 0;//当前精炼度
|
| | | if (WingDic[Index].GetUseDataModel(42) != null)
|
| | | _currentRefining = WingDic[Index].GetUseDataModel(42)[0];
|
| | |
| | | ulong haveMoney = UIHelper.GetMoneyCnt(1);
|
| | | if (haveMoney >= (ulong)config.OpenMoney)
|
| | | {
|
| | | m_Condition0.text = Language.Get("OpenBoxCostMoney", UIHelper.GetTextColorByItemColor(TextColType.Green, config.OpenMoney.ToString()));
|
| | | m_Condition0.text = Language.Get("OpenBoxCostMoney", UIHelper.AppendStringColor(TextColType.Green, config.OpenMoney.ToString()));
|
| | | }
|
| | | else
|
| | | {
|
| | | m_Condition0.text = Language.Get("OpenBoxCostMoney", UIHelper.GetTextColorByItemColor(TextColType.Red, config.OpenMoney.ToString()));
|
| | | m_Condition0.text = Language.Get("OpenBoxCostMoney", UIHelper.AppendStringColor(TextColType.Red, config.OpenMoney.ToString()));
|
| | | }
|
| | | }
|
| | | else
|
| | |
| | | {
|
| | | if (ConfirmCancel.iconHaveCnt >= ConfirmCancel.iconNeedCnt)
|
| | | {
|
| | | itemBaisc.countText.text = StringUtility.Contact(UIHelper.GetTextColorByItemColor(TextColType.Green, ConfirmCancel.iconHaveCnt.ToString(), true), "/", ConfirmCancel.iconNeedCnt);
|
| | | itemBaisc.countText.text = StringUtility.Contact(UIHelper.AppendStringColor(TextColType.Green, ConfirmCancel.iconHaveCnt.ToString(), true), "/", ConfirmCancel.iconNeedCnt);
|
| | | }
|
| | | else
|
| | | {
|
| | | itemBaisc.countText.text = StringUtility.Contact(UIHelper.GetTextColorByItemColor(TextColType.Red, ConfirmCancel.iconHaveCnt.ToString()), "/", ConfirmCancel.iconNeedCnt);
|
| | | itemBaisc.countText.text = StringUtility.Contact(UIHelper.AppendStringColor(TextColType.Red, ConfirmCancel.iconHaveCnt.ToString()), "/", ConfirmCancel.iconNeedCnt);
|
| | | }
|
| | | }
|
| | | else
|
| | |
| | | { |
| | | if (treasureConfig.PreTreasure == 0) |
| | | { |
| | | var levelLimitHint = UIHelper.GetTextColorByItemColor( |
| | | var levelLimitHint = UIHelper.AppendStringColor( |
| | | PlayerDatas.Instance.baseData.LV >= treasureConfig.ChallengeLevel ? TextColType.Green : TextColType.Red, treasureConfig.ChallengeLevel.ToString(), true); |
| | | m_LevelLimit.text = Language.Get("TreasureLevelLimit", levelLimitHint); |
| | | |
| | | } |
| | | else |
| | | { |
| | | var levelLimitHint = UIHelper.GetTextColorByItemColor( |
| | | var levelLimitHint = UIHelper.AppendStringColor( |
| | | PlayerDatas.Instance.baseData.LV >= treasureConfig.ChallengeLevel ? TextColType.Green : TextColType.Red, treasureConfig.ChallengeLevel.ToString(), true); |
| | | |
| | | var preTreasureConfig = Config.Instance.Get<TreasureConfig>(treasureConfig.PreTreasure); |
| | | var treasureLimitHint = UIHelper.GetTextColorByItemColor( |
| | | var treasureLimitHint = UIHelper.AppendStringColor( |
| | | treasure.state == TreasureState.Collecting ? TextColType.Green : TextColType.Red, preTreasureConfig.Name, true); |
| | | |
| | | m_LevelLimit.text = Language.Get("TreasureLvLimit", levelLimitHint, treasureLimitHint); |
| | |
| | | {
|
| | | if (config.PreTreasure == 0)
|
| | | {
|
| | | var levelLimitHint = UIHelper.GetTextColorByItemColor(
|
| | | var levelLimitHint = UIHelper.AppendStringColor(
|
| | | PlayerDatas.Instance.baseData.LV >= config.ChallengeLevel ? TextColType.Green : TextColType.Red, config.ChallengeLevel.ToString(), true);
|
| | | m_Limit.text = Language.Get("TreasureLevelLimit", levelLimitHint);
|
| | |
|
| | | }
|
| | | else
|
| | | {
|
| | | var levelLimitHint = UIHelper.GetTextColorByItemColor(
|
| | | var levelLimitHint = UIHelper.AppendStringColor(
|
| | | PlayerDatas.Instance.baseData.LV >= config.ChallengeLevel ? TextColType.Green : TextColType.Red, config.ChallengeLevel.ToString(), true);
|
| | |
|
| | | var preTreasureConfig = Config.Instance.Get<TreasureConfig>(config.PreTreasure);
|
| | | var treasureLimitHint = UIHelper.GetTextColorByItemColor(
|
| | | var treasureLimitHint = UIHelper.AppendStringColor(
|
| | | m_Treasure.state == TreasureState.Collecting ? TextColType.Green : TextColType.Red, preTreasureConfig.Name, true);
|
| | |
|
| | | m_Limit.text = Language.Get("TreasureLvLimit", levelLimitHint, treasureLimitHint);
|
| | |
| | | m_ContainerTip.gameObject.SetActive(true);
|
| | | var _funcConfig = Config.Instance.Get<FuncOpenLVConfig>(stage.func);
|
| | | m_NewStageTip.text = StringUtility.Contact(Language.Get("TreasureGetNewFunc"),
|
| | | UIHelper.GetTextColorByItemColor(TextColType.Green, _funcConfig.Remark));
|
| | | UIHelper.AppendStringColor(TextColType.Green, _funcConfig.Remark));
|
| | | break;
|
| | | }
|
| | | StartCoroutine(Co_StepUpComplete());
|
| | |
| | |
|
| | | var levelUpConfig = GetPotentialLevelUpConfig();
|
| | | bool satisfy = levelUpConfig.own >= levelUpConfig.need;
|
| | | m_PotentialCount.text = StringUtility.Contact(UIHelper.GetTextColorByItemColor(satisfy ?
|
| | | m_PotentialCount.text = StringUtility.Contact(UIHelper.AppendStringColor(satisfy ?
|
| | | TextColType.LightYellow : TextColType.Red, levelUpConfig.own.ToString()), "/", levelUpConfig.need);
|
| | | m_RemoveBook.gameObject.SetActive(levelUpConfig.materilaKind > 1);
|
| | | }
|
| | |
| | | DisplayPotentialBook(model.selectedPotentialBook);
|
| | | var levelUpConfig = GetPotentialLevelUpConfig();
|
| | | bool satisfy = levelUpConfig.own >= levelUpConfig.need;
|
| | | m_PotentialCount.text = StringUtility.Contact(UIHelper.GetTextColorByItemColor(satisfy ?
|
| | | m_PotentialCount.text = StringUtility.Contact(UIHelper.AppendStringColor(satisfy ?
|
| | | TextColType.LightYellow : TextColType.Red, levelUpConfig.own.ToString()), "/", levelUpConfig.need);
|
| | | }
|
| | | }
|
| | |
| | | if (model.TryGetAchievement(_achievementId, out achievement))
|
| | | {
|
| | | var progress = achievement.completed ? config.NeedCnt : Mathf.Clamp(achievement.progress, 0, config.NeedCnt);
|
| | | m_Progress.text = StringUtility.Contact("(", UIHelper.GetTextColorByItemColor(progress >= config.NeedCnt ? TextColType.Green : TextColType.Red, progress.ToString(), true)
|
| | | m_Progress.text = StringUtility.Contact("(", UIHelper.AppendStringColor(progress >= config.NeedCnt ? TextColType.Green : TextColType.Red, progress.ToString(), true)
|
| | | , "/", config.NeedCnt, ")");
|
| | | m_Complete.gameObject.SetActive(achievement.completed);
|
| | | m_Goto.gameObject.SetActive(!achievement.completed);
|
| | |
| | | case TreasurePrivilege.PetHp:
|
| | | case TreasurePrivilege.MountAtk:
|
| | | case TreasurePrivilege.Sp:
|
| | | if (state == TreasurePrivilegeState.Complete) { return UIHelper.GetTextColorByItemColor(TextColType.Green, totalProgress.ToString(), true); }
|
| | | if (state == TreasurePrivilegeState.Complete) { return UIHelper.AppendStringColor(TextColType.Green, totalProgress.ToString(), true); }
|
| | | else if (state == TreasurePrivilegeState.Doing)
|
| | | {
|
| | | return StringUtility.Contact(UIHelper.GetTextColorByItemColor(TextColType.Red, presentGetCount.ToString(), true), "/", (presentFinishCount / progress + 1) * progress);
|
| | | return StringUtility.Contact(UIHelper.AppendStringColor(TextColType.Red, presentGetCount.ToString(), true), "/", (presentFinishCount / progress + 1) * progress);
|
| | | }
|
| | | else if (state == TreasurePrivilegeState.Reward)
|
| | | {
|
| | | var _completeCount = (presentFinishCount / progress + 1) * progress;
|
| | | return StringUtility.Contact(UIHelper.GetTextColorByItemColor(TextColType.Green, presentGetCount.ToString(), true), "/", _completeCount);
|
| | | return StringUtility.Contact(UIHelper.AppendStringColor(TextColType.Green, presentGetCount.ToString(), true), "/", _completeCount);
|
| | | }
|
| | | break;
|
| | | case TreasurePrivilege.StrengthenAdd:
|
| | |
| | | || state == TreasurePrivilegeState.Reward)
|
| | | {
|
| | | var colortype = presentGetCount >= configs[next].countNeed ? TextColType.Green : TextColType.Red;
|
| | | return StringUtility.Contact(UIHelper.GetTextColorByItemColor(colortype, presentGetCount.ToString(), true), "/", configs[next].countNeed);
|
| | | return StringUtility.Contact(UIHelper.AppendStringColor(colortype, presentGetCount.ToString(), true), "/", configs[next].countNeed);
|
| | | }
|
| | | break;
|
| | | }
|
| | |
| | | {
|
| | | if(info.IsCompleted)
|
| | | {
|
| | | return UIHelper.GetTextColorByItemColor(TextColType.Green, StringUtility.Contact(info.targetNum, "/", info.targetNum));
|
| | | return UIHelper.AppendStringColor(TextColType.Green, StringUtility.Contact(info.targetNum, "/", info.targetNum));
|
| | | }
|
| | | else
|
| | | {
|
| | | if (progress < info.targetNum)
|
| | | {
|
| | | return UIHelper.GetTextColorByItemColor(TextColType.Red, StringUtility.Contact(progress, "/", info.targetNum), true);
|
| | | return UIHelper.AppendStringColor(TextColType.Red, StringUtility.Contact(progress, "/", info.targetNum), true);
|
| | | }
|
| | | else
|
| | | {
|
| | | return UIHelper.GetTextColorByItemColor(TextColType.Green, StringUtility.Contact(progress, "/", info.targetNum));
|
| | | return UIHelper.AppendStringColor(TextColType.Green, StringUtility.Contact(progress, "/", info.targetNum));
|
| | | }
|
| | | }
|
| | | }
|
| | |
| | | {
|
| | | effect.Stop();
|
| | | }
|
| | | progressText.text = UIHelper.GetTextColorByItemColor(TextColType.Green,StringUtility.Contact("(",progress,"/",findInfolist.Count,")"), true);
|
| | | progressText.text = UIHelper.AppendStringColor(TextColType.Green,StringUtility.Contact("(",progress,"/",findInfolist.Count,")"), true);
|
| | | }
|
| | | else
|
| | | {
|
| | |
| | | {
|
| | | effect.Stop();
|
| | | }
|
| | | progressText.text = UIHelper.GetTextColorByItemColor(TextColType.Red, StringUtility.Contact("(",progress, "/", findInfolist.Count,")"));
|
| | | progressText.text = UIHelper.AppendStringColor(TextColType.Red, StringUtility.Contact("(",progress, "/", findInfolist.Count,")"));
|
| | | }
|
| | | gotoBtn.gameObject.SetActive(true);
|
| | | if (treasure.state == TreasureState.Collected)
|
| | |
| | | GetFairyJade();
|
| | | if (InvestInfo.curDay <= 0)
|
| | | {
|
| | | m_RemainingDays.text = string.Format(Language.Get("TheRemainingNumberDays_Z"), UIHelper.GetTextColorByItemColor(TextColType.Green, 0.ToString(), true));
|
| | | m_RemainingDays.text = string.Format(Language.Get("TheRemainingNumberDays_Z"), UIHelper.AppendStringColor(TextColType.Green, 0.ToString(), true));
|
| | | }
|
| | | else
|
| | | {
|
| | |
| | | {
|
| | | Day = 7 - InvestInfo.curDay;
|
| | | }
|
| | | m_RemainingDays.text = string.Format(Language.Get("TheRemainingNumberDays_Z"), UIHelper.GetTextColorByItemColor(TextColType.Green, Day.ToString(), true));
|
| | | m_RemainingDays.text = string.Format(Language.Get("TheRemainingNumberDays_Z"), UIHelper.AppendStringColor(TextColType.Green, Day.ToString(), true));
|
| | | }
|
| | |
|
| | | if (InvestInfo.investGold <= 0)
|
| | |
| | | }
|
| | | if (InvestInfo.curDay <= 0)
|
| | | {
|
| | | m_RemainingDays.text = string.Format(Language.Get("TheRemainingNumberDays_Z"), UIHelper.GetTextColorByItemColor(TextColType.Green, 0.ToString(), true));
|
| | | m_RemainingDays.text = string.Format(Language.Get("TheRemainingNumberDays_Z"), UIHelper.AppendStringColor(TextColType.Green, 0.ToString(), true));
|
| | | }
|
| | | else
|
| | | {
|
| | |
| | | {
|
| | | Day = 7 - InvestInfo.curDay;
|
| | | }
|
| | | m_RemainingDays.text = string.Format(Language.Get("TheRemainingNumberDays_Z"), UIHelper.GetTextColorByItemColor(TextColType.Green, Day.ToString(), true));
|
| | | m_RemainingDays.text = string.Format(Language.Get("TheRemainingNumberDays_Z"), UIHelper.AppendStringColor(TextColType.Green, Day.ToString(), true));
|
| | | }
|
| | | }
|
| | | }
|
| | |
| | | }
|
| | | return null;
|
| | | }
|
| | |
|
| | | Dictionary<int, int> fightPowerDict = new Dictionary<int, int>();
|
| | | public int GetTitlePower(int vipLv)
|
| | | {
|
| | | int[] typearray = DienstgradConfig.GetTitleAttrType(vipTitleDic[vipLv]);
|
| | | int[] valarray = DienstgradConfig.GetTitleAttrValue(vipTitleDic[vipLv]);
|
| | | int[] array = new int[typearray.Length * 2];
|
| | | for (int i = 0; i < typearray.Length; i++)
|
| | | int[] propertys = DienstgradConfig.GetTitleAttrType(vipTitleDic[vipLv]);
|
| | | int[] values = DienstgradConfig.GetTitleAttrValue(vipTitleDic[vipLv]);
|
| | | fightPowerDict.Clear();
|
| | | for (int i = 0; i < propertys.Length; i++)
|
| | | {
|
| | | array[i * 2] = typearray[i];
|
| | | array[i * 2 + 1] = valarray[i];
|
| | | fightPowerDict.Add(propertys[i], values[i]);
|
| | | }
|
| | | if (typearray != null && valarray != null && typearray.Length == valarray.Length)
|
| | | {
|
| | | return (int)UIHelper.GetFightPower(array);
|
| | | }
|
| | | return 0;
|
| | | return (int)UIHelper.GetFightPower(fightPowerDict);
|
| | | }
|
| | |
|
| | | private void ParseVipTime()
|
| | |
| | | }
|
| | | else
|
| | | {
|
| | | remainTimeText.text = UIHelper.GetTextColorByItemColor(TextColType.Red, Language.Get("XMZZ110"));
|
| | | remainTimeText.text = UIHelper.AppendStringColor(TextColType.Red, Language.Get("XMZZ110"));
|
| | | }
|
| | | }
|
| | |
|
| | |
| | | }
|
| | | private static Regex m_TextColorRegex = new Regex("<color=#[0-9a-zA-Z]+>(.*)</color>", RegexOptions.Singleline);
|
| | |
|
| | | public static string GetTextColorByItemColor(TextColType type, string msg, bool bright = false)
|
| | | public static string AppendStringColor(TextColType type, string msg, bool bright = false)
|
| | | {
|
| | | if (m_TextColorRegex.IsMatch(msg))
|
| | | {
|
| | |
| | | }
|
| | | }
|
| | |
|
| | | public static string GetTextColorByItemColor(int itemColor, string msg, bool bright = false)
|
| | | public static string AppendStringColor(int itemColor, string msg, bool bright = false)
|
| | | {
|
| | | switch (itemColor)
|
| | | {
|
| | | case 0:
|
| | | case 1:
|
| | | return GetTextColorByItemColor(TextColType.White, msg, bright);
|
| | | return AppendStringColor(TextColType.White, msg, bright);
|
| | | case 2:
|
| | | return GetTextColorByItemColor(TextColType.Blue, msg, bright);
|
| | | return AppendStringColor(TextColType.Blue, msg, bright);
|
| | | case 3:
|
| | | return GetTextColorByItemColor(TextColType.Purple, msg, bright);
|
| | | return AppendStringColor(TextColType.Purple, msg, bright);
|
| | | case 4:
|
| | | return GetTextColorByItemColor(TextColType.Orange, msg, bright);
|
| | | return AppendStringColor(TextColType.Orange, msg, bright);
|
| | | case 5:
|
| | | return GetTextColorByItemColor(TextColType.Red, msg, bright);
|
| | | return AppendStringColor(TextColType.Red, msg, bright);
|
| | | case 6:
|
| | | return GetTextColorByItemColor(TextColType.Pink, msg, bright);
|
| | | return AppendStringColor(TextColType.Pink, msg, bright);
|
| | | }
|
| | | return msg;
|
| | | }
|
| | |
| | |
|
| | | #region 计算战斗力
|
| | | public static readonly string FightPowerFormula = "FightpowerFormula";
|
| | | public static uint GetFightPower(params int[] paraArray)
|
| | | {
|
| | | Equation.Instance.Clear();
|
| | | if (paraArray == null || paraArray.Length < 2 || paraArray.Length % 2 != 0) return 0;
|
| | | for (int i = 0; i < paraArray.Length; i += 2)
|
| | | {
|
| | | PlayerPropertyConfig cfg = Config.Instance.Get<PlayerPropertyConfig>(paraArray[i]);
|
| | | if (cfg != null)
|
| | | {
|
| | | if (paraArray[i] == 7)
|
| | | {
|
| | | Equation.Instance.AddKeyValue("MinAtk", paraArray[i + 1]);
|
| | | Equation.Instance.AddKeyValue("MaxAtk", paraArray[i + 1]);
|
| | | }
|
| | | else
|
| | | {
|
| | | Equation.Instance.AddKeyValue(cfg.Parameter, paraArray[i + 1]);
|
| | | }
|
| | | }
|
| | | }
|
| | | FuncConfigConfig funcCfg = Config.Instance.Get<FuncConfigConfig>(FightPowerFormula);
|
| | | return Equation.Instance.Eval<uint>(funcCfg.Numerical1);
|
| | | }
|
| | |
|
| | | public static int GetFightPower(Dictionary<int, int> _propertyDict)
|
| | | {
|
| | | Equation.Instance.Clear();
|