//던전 클리어_ WorkListController _ 7 번에서 호출. public void Dungeon_Clear(int dpNum) { DungeonProgress dp = DungeonData.Instance.dungeon_Progress[dpNum]; //보상등록 Dungeon_Reward dr = DungeonData.Instance.dungeon_Rewards[dp.p.dayIndex]; PlayerData.Instance.Gold += dp.Get_Dungeon_Reward_Gold(); dp.SearchP += (int)dr.search; //파티해제 foreach (int k in dp.p.k) { UnitData.Instance.knights[k].teaming = false; } UnitData.Instance.partys.Remove(dp.p); //모드 변경 dp.Dungeon_Reset(); GameController.Instance.world.WorkList_Update();//화면 업뎃 GameController.Instance.EventCheck(); }
public void SelectDungeon(int _index) { //기본 던전 정보 index = _index; gameObject.SetActive(true); DungeonProgress dp = DungeonData.Instance.dungeon_Progress [index]; dungeon_Name_Text.text = dp.d.name; dungeon_Level_Text.text = index < 2 ? "LV.1" : index < 5 ? "LV.2" : index < 7 ? "LV.3" : "LV.4"; dungoen_SearchPer_Text.text = string.Format("{0}%", dp.SearchP); dungeon_SaturationPer_Text.text = string.Format("{0}%", dp.Saturation); type = DungeonData.Instance.dungeon_Progress[index].eventType; //화면 세팅 /* 0 : none(출전가능한) * 1 : 전투 * 2 : NON Event (그냥 탐색.) * 3 : Choice Event(선택지 이벤트, dp - choice_Event_Type 값 참조) * * n : 자연지형에 의한 선택지 * n : 동료간 대화에 의한 선택지 * n : 기록의 발견(SearchPer 첫달성시) * * 7 : 일정대로 진행 후 귀환함. * 8 : 0의 제외한 이벤트 후 귀환 요청이 가능한 화면 */ for (int i = 0; i < 9; i++) { workTypeObj[i].SetActive(false); } workTypeObj[type].SetActive(true); switch (type) { case 1: workTypeObj[type].GetComponentInChildren <Text>().text = string.Format("X {0}", dp.m.Length); break; case 7: reward_Gold_Text.text = string.Format("{0}G", dp.Get_Dungeon_Reward_Gold()); reward_SearchPer_Text.text = string.Format("+{0}%", dp.Get_Dungeon_Reward_SearchPer()); break; default: break; } workTypeObj[type].SetActive(true); //멘트 button_Ment_Text.text = TextData.Instance.workList_Button_Ment_Text[type]; info_Ment_Text.text = TextData.Instance.workList_Info_Ment_Text[type]; // button.Interactable = n == CodeBox.ClearList(partyInfo_ListTr); partyInfo_Obj.SetActive(type != 0); if (type != 0) { party_Gold_Text.text = string.Format("{0}G", dp.Reward); party_Turn_Text.text = string.Format("{0}T", dp.p.day); } if (type != 0 && type != 7) { PartyInfoViewer(); } }