public bool CanVersionUp()
        {
            bool result = false;

            if (MonsterGrowStepData.IsUltimateScope(this.monsterMaster.Group.growStep) && int.Parse(this.monsterMaster.Simple.rare) == 5)
            {
                result = true;
            }
            return(result);
        }
 public static bool IsUltimateScope(string growStep)
 {
     return(MonsterGrowStepData.IsUltimateScope(MonsterGrowStepData.ToGrowStep(growStep)));
 }
Пример #3
0
        public static List <MonsterData> Filter(List <MonsterData> targetMonsterList, MonsterFilterType type)
        {
            List <MonsterData> list = new List <MonsterData>();

            switch (type)
            {
            case MonsterFilterType.GROWING_IN_GARDEN:
                for (int i = 0; i < targetMonsterList.Count; i++)
                {
                    bool flag = MonsterGrowStepData.IsGardenDigimonScope(targetMonsterList[i].GetMonsterMaster().Group.growStep);
                    if (flag && (targetMonsterList[i].GetMonster().IsEgg() || !string.IsNullOrEmpty(targetMonsterList[i].GetMonster().growEndDate)))
                    {
                        list.Add(targetMonsterList[i]);
                    }
                }
                break;

            case MonsterFilterType.ALL_OUT_GARDEN:
                for (int j = 0; j < targetMonsterList.Count; j++)
                {
                    if (!MonsterGrowStepData.IsGardenDigimonScope(targetMonsterList[j].GetMonsterMaster().Group.growStep))
                    {
                        list.Add(targetMonsterList[j]);
                    }
                }
                break;

            case MonsterFilterType.RESEARCH_TARGET:
                for (int k = 0; k < targetMonsterList.Count; k++)
                {
                    if (MonsterGrowStepData.IsUltimateScope(targetMonsterList[k].GetMonsterMaster().Group.growStep))
                    {
                        list.Add(targetMonsterList[k]);
                    }
                }
                break;

            case MonsterFilterType.CAN_EVOLVE:
                for (int l = 0; l < targetMonsterList.Count; l++)
                {
                    if (!MonsterGrowStepData.IsGardenDigimonScope(targetMonsterList[l].GetMonsterMaster().Group.growStep))
                    {
                        List <GameWebAPI.RespDataMA_GetMonsterEvolutionM.Evolution> evoList = ClassSingleton <EvolutionData> .Instance.GetEvoList(targetMonsterList[l].GetMonster().monsterId);

                        if (0 < evoList.Count)
                        {
                            list.Add(targetMonsterList[l]);
                        }
                    }
                }
                break;

            case MonsterFilterType.ALL_IN_GARDEN:
                for (int m = 0; m < targetMonsterList.Count; m++)
                {
                    if (MonsterGrowStepData.IsGardenDigimonScope(targetMonsterList[m].GetMonsterMaster().Group.growStep))
                    {
                        list.Add(targetMonsterList[m]);
                    }
                }
                break;

            case MonsterFilterType.HAVE_MEDALS:
                list = MonsterFilter.SelectionMedal(targetMonsterList, true);
                break;

            case MonsterFilterType.CAN_VERSION_UP:
                for (int n = 0; n < targetMonsterList.Count; n++)
                {
                    if (targetMonsterList[n].CanVersionUp())
                    {
                        List <GameWebAPI.RespDataMA_GetMonsterEvolutionM.Evolution> monsterVersionUpList = ClassSingleton <EvolutionData> .Instance.GetMonsterVersionUpList(targetMonsterList[n].GetMonsterMaster().Simple.monsterId);

                        if (0 < monsterVersionUpList.Count)
                        {
                            list.Add(targetMonsterList[n]);
                        }
                    }
                }
                break;

            case MonsterFilterType.ALL_VERSION_UP:
                for (int num = 0; num < targetMonsterList.Count; num++)
                {
                    if (MonsterStatusData.IsVersionUp(targetMonsterList[num].GetMonsterMaster().Simple.rare))
                    {
                        list.Add(targetMonsterList[num]);
                    }
                }
                break;
            }
            return(list);
        }
 public static bool IsUltimateScope(int growStep)
 {
     return(MonsterGrowStepData.IsUltimateScope((GrowStep)growStep));
 }