public void SetViewNextEvolutionMonster(string monsterId, GameWebAPI.RespDataUS_GetMonsterList.UserMonsterList userMonster) { GameWebAPI.RespDataMA_GetMonsterMS.MonsterM simple = MonsterMaster.GetMonsterMasterByMonsterId(monsterId).Simple; GameWebAPI.RespDataMA_GetMonsterMG.MonsterM group = MonsterMaster.GetMonsterMasterByMonsterGroupId(simple.monsterGroupId).Group; DataMng.ExperienceInfo experienceInfo = DataMng.Instance().GetExperienceInfo(0); MonsterData monsterData = new MonsterData(new GameWebAPI.RespDataUS_GetMonsterList.UserMonsterList(userMonster) { monsterId = monsterId, level = "1", ex = "0", levelEx = "0", nextLevelEx = experienceInfo.expLevNext.ToString() }); if (!string.IsNullOrEmpty(group.leaderSkillId) && "0" != group.leaderSkillId) { monsterData.userMonster.leaderSkillId = group.leaderSkillId; monsterData.InitSkillInfo(); } StatusValue statusValue = MonsterStatusData.GetStatusValue(monsterId, "1"); statusValue.luck = int.Parse(userMonster.luck); monsterData.SetStatus(statusValue); CMD_CharacterDetailed.DataChg = monsterData; GameWebAPI.RespDataMA_GetMonsterResistanceM.MonsterResistanceM resistanceMaster = MonsterResistanceData.GetResistanceMaster(monsterData.monsterM.resistanceId); bool active = this.AnyMatchStrongResistance(resistanceMaster, userMonster.tranceResistance, userMonster.tranceStatusAilment); this.nextMonsterResistanceAlert.gameObject.SetActive(active); }
private void OfflineGrow_Step2(MonsterData monsterData) { MonsterClientMaster monsterMaster = monsterData.GetMonsterMaster(); string modelId = monsterMaster.Group.modelId; string growStep = monsterMaster.Group.growStep; string userMonsterId = monsterData.GetMonster().userMonsterId; string monsterEvolutionRouteId = monsterData.GetMonster().monsterEvolutionRouteId; foreach (GameWebAPI.RespDataMA_GetMonsterEvolutionRouteM.MonsterEvolutionRouteM monsterEvolutionRouteM2 in MasterDataMng.Instance().RespDataMA_MonsterEvolutionRouteM.monsterEvolutionRouteM) { if (monsterEvolutionRouteId == monsterEvolutionRouteM2.monsterEvolutionRouteId) { monsterData = MonsterDataMng.Instance().CreateMonsterDataByMID(monsterEvolutionRouteM2.growthMonsterId); break; } } MonsterDataMng.Instance().GetMonsterDataList()[0].userMonster.growEndDate = string.Empty; monsterData.userMonster.ex = "0"; monsterData.userMonster.hpAbilityFlg = "0"; monsterData.userMonster.attackAbilityFlg = "0"; monsterData.userMonster.defenseAbilityFlg = "0"; monsterData.userMonster.spAttackAbilityFlg = "0"; monsterData.userMonster.spDefenseAbilityFlg = "0"; monsterData.userMonster.speedAbilityFlg = "0"; monsterData.userMonster.friendship = "0"; StatusValue statusValue = MonsterStatusData.GetStatusValue(monsterData.userMonster.monsterId, monsterData.userMonster.level); statusValue.luck = 1; monsterData.SetStatus(statusValue); monsterData.userMonster.userMonsterId = userMonsterId; ClassSingleton <MonsterUserDataMng> .Instance.UpdateUserMonsterData(monsterData.userMonster); ClassSingleton <GUIMonsterIconList> .Instance.RefreshList(MonsterDataMng.Instance().GetMonsterDataList()); monsterData = ClassSingleton <MonsterUserDataMng> .Instance.GetUserMonster(userMonsterId); monsterMaster = monsterData.GetMonsterMaster(); CutsceneDataEvolution cutsceneDataEvolution = new CutsceneDataEvolution(); cutsceneDataEvolution.path = "Cutscenes/Evolution"; cutsceneDataEvolution.beforeModelId = modelId; cutsceneDataEvolution.beforeGrowStep = growStep; cutsceneDataEvolution.afterModelId = monsterMaster.Group.modelId; cutsceneDataEvolution.afterGrowStep = monsterMaster.Group.growStep; cutsceneDataEvolution.endCallback = delegate() { FarmCameraControlForCMD.On(); CutSceneMain.FadeReqCutSceneEnd(); }; CutsceneDataEvolution cutsceneData = cutsceneDataEvolution; this.CallEvolutionCutScene(monsterData, cutsceneData); }