| | |
| | | if (mountRedpoint.Count != 0)
|
| | | return;
|
| | |
|
| | | // var configs = Config.Instance.GetAllValues<HorseConfig>();
|
| | | // var configs = Config.Instance.GetAllValues<HorseConfig>();
|
| | | if (Hconfigs.Count <= 0)
|
| | | {
|
| | | Hconfigs = Config.Instance.GetAllValues<HorseConfig>();
|
| | |
| | | {
|
| | | Hconfigs = Config.Instance.GetAllValues<HorseConfig>();
|
| | | }
|
| | | // var configs = Config.Instance.GetAllValues<HorseConfig>();
|
| | | // var configs = Config.Instance.GetAllValues<HorseConfig>();
|
| | | foreach (var config in Hconfigs)
|
| | | {
|
| | | int unlockItemID = config.UnlockItemID;
|
| | |
| | | return;
|
| | | if (Uconfigs.Count <= 0)
|
| | | {
|
| | | Uconfigs= Config.Instance.GetAllValues<HorseUpConfig>();
|
| | | Uconfigs = Config.Instance.GetAllValues<HorseUpConfig>();
|
| | | }
|
| | | //var configs = Config.Instance.GetAllValues<HorseUpConfig>();
|
| | | foreach (var config in Uconfigs)
|
| | |
| | | {
|
| | | return;
|
| | | }
|
| | |
|
| | | int GetMountID = 0;
|
| | | int GetMountLv = 0;
|
| | | int NeedExp = 99999999;
|
| | | int NeedNumber = 0;//所需要的经验丹
|
| | | List<int> IntList = new List<int>();
|
| | | FuncConfigConfig _tagfun = Config.Instance.Get<FuncConfigConfig>("HorseUpItem");
|
| | | ItemConfig _tagchine = Config.Instance.Get<ItemConfig>(int.Parse(_tagfun.Numerical1));
|
| | | int number = playerPack.GetItemCountByID(PackType.rptItem, _tagchine.ID);
|
| | | for (int i = 0; i < SortMount.Count; i++)
|
| | | {
|
| | | int horseID = SortMount[i].HorseID;
|
| | | if (_DicHorse.ContainsKey(horseID) && _DicHorse[horseID].Lv < Config.Instance.Get<HorseConfig>(horseID).MaxLV)
|
| | | int MaxLv = Config.Instance.Get<HorseConfig>(horseID).MaxLV;
|
| | | if (_DicHorse.ContainsKey(horseID) && _DicHorse[horseID].Lv < MaxLv)
|
| | | {
|
| | | int _NeedExp = HorseUpConfig.GetHorseIDAndLV(horseID, (_DicHorse[horseID].Lv)).NeedExp;
|
| | | if (_NeedExp - _DicHorse[horseID].Exp < NeedExp)
|
| | | int NeedExp = _NeedExp - _DicHorse[horseID].Exp;
|
| | | int NeedNumber = Mathf.CeilToInt((float)NeedExp / HorseDanExp);
|
| | | if (number >= NeedNumber)
|
| | | {
|
| | | NeedExp = _NeedExp - _DicHorse[horseID].Exp;
|
| | | GetMountID = horseID;
|
| | | GetMountLv = _DicHorse[horseID].Lv;
|
| | | NeedNumber = Mathf.CeilToInt((float)NeedExp / HorseDanExp);
|
| | | IntList.Add(horseID);
|
| | | }
|
| | | }
|
| | | }
|
| | | FuncConfigConfig _tagfun = Config.Instance.Get<FuncConfigConfig>("HorseUpItem");
|
| | | ItemConfig _tagchine = Config.Instance.Get<ItemConfig>(int.Parse(_tagfun.Numerical1));
|
| | | HorseConfig horsecon = Config.Instance.Get<HorseConfig>(GetMountID);
|
| | | int number = playerPack.GetItemCountByID(PackType.rptItem, _tagchine.ID);
|
| | |
|
| | | foreach (var key in _DicHorse.Keys)//因为有成就任务限制所有 第一只坐骑红点逻辑特殊写
|
| | | {
|
| | | if (DicDefaultMount.ContainsKey(key) && DicDefaultMount[key] > _DicHorse[key].Lv
|
| | |
| | | return;
|
| | | }
|
| | | }
|
| | | if (ASingleFeedRedPoint.ContainsKey(GetMountID) && number >= NeedNumber && GetMountLv < horsecon.MaxLV)
|
| | | int GetMinLV = 100;
|
| | | int GetMountID = 0;
|
| | | for (int j = 0; j < SortMount.Count; j++)
|
| | | {
|
| | | int Id = SortMount[j].HorseID;
|
| | | if (IntList.Contains(Id) && _DicHorse.ContainsKey(Id))
|
| | | {
|
| | | if (_DicHorse[Id].Lv < GetMinLV)
|
| | | {
|
| | | GetMinLV = _DicHorse[Id].Lv;
|
| | | GetMountID = Id;
|
| | | }
|
| | | }
|
| | | }
|
| | | if (ASingleFeedRedPoint.ContainsKey(GetMountID))
|
| | | {
|
| | | ASingleFeedRedPoint[GetMountID].state = RedPointState.Simple;
|
| | | return;
|
| | |
| | | {
|
| | | Hconfigs = Config.Instance.GetAllValues<HorseConfig>();
|
| | | }
|
| | | // var configs = Config.Instance.GetAllValues<HorseConfig>();
|
| | | // var configs = Config.Instance.GetAllValues<HorseConfig>();
|
| | | foreach (var config in Hconfigs)
|
| | | {
|
| | | if (config.ItemID == info.itemInfo.ItemID)
|