| | |
| | | public Dictionary<int, string> petAndMountQualityDict = new Dictionary<int, string>();
|
| | | public Dictionary<int, List<int>> itemParamsDict { get; private set; }
|
| | | public string expValueFormula = "";
|
| | |
|
| | | public Dictionary<int, string> exhaustedAttrFormula { get; private set; }
|
| | | public Dictionary<int, int> exhaustedMaxLvDict { get; private set; }
|
| | | public int[] guardAutoDrops;
|
| | |
|
| | | public int[] gemOpenLvs { get; private set; }
|
| | |
| | | m_storeModel.RefreshTCBPlayerDataEvent += RefreshOfflinePluginTime;
|
| | |
|
| | | exhaustedFunc = Config.Instance.Get<FuncConfigConfig>("OutOfPrintValue");
|
| | | exhaustedAttrFormula = new Dictionary<int, string>();
|
| | | JsonData exhaustedJsonData = JsonMapper.ToObject(exhaustedFunc.Numerical2);
|
| | | foreach(var key in exhaustedJsonData.Keys)
|
| | | {
|
| | | int attrId = int.Parse(key);
|
| | | exhaustedAttrFormula.Add(attrId,exhaustedJsonData[key].ToString());
|
| | | }
|
| | |
|
| | | FuncConfigConfig OutOfPrintValueDes = Config.Instance.Get<FuncConfigConfig>("OutOfPrintValueDes");
|
| | | exhaustedMaxLvDict = ConfigParse.GetDic<int, int>(OutOfPrintValueDes.Numerical1);
|
| | |
|
| | | FuncConfigConfig suitlimitModel = Config.Instance.Get<FuncConfigConfig>("EquipSuitLimit");
|
| | | equipSuitStar = int.Parse(suitlimitModel.Numerical2);
|
| | |
|
| | |
| | | #region 设置绝版属性
|
| | | public string GetExhaustedAtrr(ItemAttrData attrData)
|
| | | {
|
| | | return SetExhaustedAttr(attrData.exhaustedMaxDataDict.Keys.ToList(),attrData.exhaustedMaxDataDict.Values.ToList());
|
| | | return SetExhaustedAttr(attrData,attrData.exhaustedMaxDataDict.Keys.ToList(),attrData.exhaustedMaxDataDict.Values.ToList());
|
| | | }
|
| | |
|
| | | //即将丢弃
|
| | | public string GetEquipExhaustedAtrr(List<int> idlist, List<int> valuelist)
|
| | | {
|
| | | return SetExhaustedAttr(idlist, valuelist);
|
| | | //return SetExhaustedAttr(idlist, valuelist);
|
| | | return "";
|
| | | }
|
| | |
|
| | | private string SetExhaustedAttr(List<int> idlist, List<int> valuelist)
|
| | | private string SetExhaustedAttr(ItemAttrData attrData,List<int> idlist, List<int> valuelist)
|
| | | {
|
| | | if (idlist == null)
|
| | | return "";
|
| | |
| | | switch ((AttrEnum)idlist[i])
|
| | | {
|
| | | case AttrEnum.OnlyFinalHurt:
|
| | | s = Language.Get("EquipTip_ExtraDamage",GetExhaustedAttrValue(valuelist[i]),valuelist[i]);
|
| | | s = Language.Get("EquipTip_ExtraDamage",GetExhaustedAttrValue(idlist[i],valuelist[i]),GetExhaustedMaxLv(attrData.itemConfig.LV),valuelist[i]);
|
| | | break;
|
| | | case AttrEnum.PVPAtkBackHP:
|
| | | s = Language.Get("EquipTip_ExtraHpBack", GetExhaustedAttrValue(valuelist[i]), valuelist[i]);
|
| | | s = Language.Get("EquipTip_ExtraHpBack", GetExhaustedAttrValue(idlist[i], valuelist[i]), GetExhaustedMaxLv(attrData.itemConfig.LV), valuelist[i]);
|
| | | break;
|
| | | }
|
| | |
|
| | |
| | | return attrSB.ToString();
|
| | | }
|
| | |
|
| | | private int GetExhaustedAttrValue(int value)
|
| | | private int GetExhaustedAttrValue(int attrId,int value)
|
| | | {
|
| | | Equation.Instance.Clear();
|
| | | Equation.Instance.AddKeyValue("maxOOPValue",value);
|
| | | Equation.Instance.AddKeyValue("lv", PlayerDatas.Instance.baseData.LV);
|
| | | return Equation.Instance.Eval<int>(exhaustedFunc.Numerical1);
|
| | | string formula = string.Empty;
|
| | | if(exhaustedAttrFormula.ContainsKey(attrId))
|
| | | {
|
| | | formula = exhaustedAttrFormula[attrId];
|
| | | }
|
| | | return Equation.Instance.Eval<int>(formula);
|
| | | }
|
| | |
|
| | | public int GetExhaustedMaxLv(int equipLV)
|
| | | {
|
| | | int maxLv = 0;
|
| | | exhaustedMaxLvDict.TryGetValue(equipLV,out maxLv);
|
| | | return maxLv;
|
| | | }
|
| | | #endregion
|
| | |
|