private static bool CheckMaterialNum(GameWebAPI.RespDataMA_GetMonsterMS.MonsterM monsterM, List <HaveSoulData> almightyHsdL) { List <GameWebAPI.RespDataMA_GetMonsterEvolutionM.Evolution> monsterVersionUpList = ClassSingleton <EvolutionData> .Instance.GetMonsterVersionUpList(monsterM.monsterId); int monsterEvolutionMaterialId = monsterVersionUpList[0].monsterEvolutionMaterialId; bool result = true; GameWebAPI.MonsterEvolutionMaterialMaster.Material evolutionMaterial = EvolutionMaterialData.GetEvolutionMaterial(monsterEvolutionMaterialId); for (int i = 1; i <= 7; i++) { string assetValue = evolutionMaterial.GetAssetValue(i); string assetNum = evolutionMaterial.GetAssetNum(i); int num = assetNum.ToInt32(); GameWebAPI.UserSoulData userSoulDataBySID = VersionUpMaterialData.GetUserSoulDataBySID(assetValue); int num2 = userSoulDataBySID.num.ToInt32(); if (num > num2) { HaveSoulData haveSoulData = null; bool flag = VersionUpMaterialData.CanChangeToAlmighty(almightyHsdL, assetValue, num, ref haveSoulData); if (!flag) { result = false; break; } } } return(result); }
public static bool CanChangeToAlmighty(List <HaveSoulData> hsdL, string soulId, int needNum, ref HaveSoulData selectAlMighty) { GameWebAPI.RespDataMA_GetSoulM respDataMA_SoulM = MasterDataMng.Instance().RespDataMA_SoulM; GameWebAPI.RespDataMA_GetSoulM.SoulM soulMasterBySoulId = VersionUpMaterialData.GetSoulMasterBySoulId(soulId); if (respDataMA_SoulM.IsVersionUpGroup(soulMasterBySoulId) && !respDataMA_SoulM.IsVersionUpAlMighty(soulMasterBySoulId)) { for (int i = 0; i < hsdL.Count; i++) { if (hsdL[i].haveNum - hsdL[i].curUsedNum >= needNum) { selectAlMighty = hsdL[i]; return(true); } } } return(false); }