diff --git a/Assets/ResWork/Table/Export/DungeonMapConfig.json b/Assets/ResWork/Table/Export/DungeonMapConfig.json index 3d023822c..349e3a79b 100644 --- a/Assets/ResWork/Table/Export/DungeonMapConfig.json +++ b/Assets/ResWork/Table/Export/DungeonMapConfig.json @@ -1 +1 @@ -[{"e_DungeonType": "맵 종류", "n_MapLv": "맵 Lv", "n_MobCount": "등장 몬스터 수", "n_SpawnID": "AppearTable", "n_MobID": "MonsterListTable", "f_MakeGap": "생성 주기", "f_Time": "제한 시간(초)"}, {"e_DungeonType": "d1_Mimic", "n_MapLv": "1", "n_MobCount": "50", "n_SpawnID": "1", "n_MobID": "1001", "f_MakeGap": "0.4", "f_Time": "30"}, {"e_DungeonType": "d1_Mimic", "n_MapLv": "2", "n_MobCount": "60", "n_SpawnID": "2", "n_MobID": "1001", "f_MakeGap": "0.4", "f_Time": "30"}, {"e_DungeonType": "d2_Maze", "n_MapLv": "1", "n_MobCount": "20", "n_SpawnID": "1", "n_MobID": "0", "f_MakeGap": "0", "f_Time": "90"}, {"e_DungeonType": "d3_Nightmare", "n_MapLv": "1", "n_MobCount": "3", "n_SpawnID": "1", "n_MobID": "1003", "f_MakeGap": "0", "f_Time": "90"}, {"e_DungeonType": "d4_Wave", "n_MapLv": "1", "n_MobCount": "100", "n_SpawnID": "1", "n_MobID": "0", "f_MakeGap": "10", "f_Time": "1800"}] \ No newline at end of file +[{"e_DungeonType": "맵 종류", "n_MapLv": "맵 Lv", "n_MobCount": "등장 몬스터 수", "n_SpawnID": "AppearTable", "n_MobID": "MonsterListTable", "f_MakeGap": "생성 주기", "f_Time": "제한 시간(초)", "f_Increase": "강해지는 비율"}, {"e_DungeonType": "d1_Mimic", "n_MapLv": "1", "n_MobCount": "50", "n_SpawnID": "1", "n_MobID": "1001", "f_MakeGap": "0.4", "f_Time": "30", "f_Increase": "0"}, {"e_DungeonType": "d1_Mimic", "n_MapLv": "2", "n_MobCount": "60", "n_SpawnID": "2", "n_MobID": "1001", "f_MakeGap": "0.4", "f_Time": "30", "f_Increase": "0"}, {"e_DungeonType": "d2_Maze", "n_MapLv": "1", "n_MobCount": "20", "n_SpawnID": "1", "n_MobID": "0", "f_MakeGap": "0", "f_Time": "90", "f_Increase": "0.5"}, {"e_DungeonType": "d3_Nightmare", "n_MapLv": "1", "n_MobCount": "3", "n_SpawnID": "1", "n_MobID": "1003", "f_MakeGap": "0", "f_Time": "90", "f_Increase": "0"}, {"e_DungeonType": "d4_Wave", "n_MapLv": "1", "n_MobCount": "100", "n_SpawnID": "1", "n_MobID": "0", "f_MakeGap": "60", "f_Time": "1800", "f_Increase": "0.1"}] \ No newline at end of file diff --git a/Assets/ResWork/Table/butler.xlsm b/Assets/ResWork/Table/butler.xlsm index 821ce33a2..814c99016 100644 Binary files a/Assets/ResWork/Table/butler.xlsm and b/Assets/ResWork/Table/butler.xlsm differ diff --git a/Assets/Script/Character/Actor.cs b/Assets/Script/Character/Actor.cs index 03ab14cc0..21409b338 100644 --- a/Assets/Script/Character/Actor.cs +++ b/Assets/Script/Character/Actor.cs @@ -1767,7 +1767,7 @@ public class Actor : MyCoroutine return true; case NavMeshPathStatus.PathPartial: ++FindCount; - Debug.Log($"Path Partial. Attempt: {FindCount}"); + //Debug.Log($"Path Partial. Attempt: {FindCount}"); if (FindCount > 5) { FindCount = 0; diff --git a/Assets/Script/Character/Mob/MobActor.cs b/Assets/Script/Character/Mob/MobActor.cs index 6f77d2018..f3ed416dc 100644 --- a/Assets/Script/Character/Mob/MobActor.cs +++ b/Assets/Script/Character/Mob/MobActor.cs @@ -12,7 +12,7 @@ public class MobActor : Actor protected int m_SpawnerId; protected eMobStatus MobStatus; Vector3 OriginalPos, TargetPatrolPos; - float m_PatrolDelay, m_DieTime; + float m_PatrolDelay, m_DieTime, f_BaseChaseRange; bool b_IsFirstAttack, NoUpdate_byTool; protected MonsterAppearData m_MonsterAppearData; protected MonsterTableData m_MonsterTableData; @@ -61,6 +61,7 @@ public class MobActor : Actor m_AttackType = m_MonsterTableData.e_AttackType; b_IsFirstAttack = m_MonsterTableData.b_IsFirstAttack; + f_BaseChaseRange = m_MonsterTableData.f_BaseChaseRange; //var chapter = InGameInfo.Ins.Get_CurStageData().Chapter; //if (IsBoss && chapter < 101) { GameUI.Ins.IngameUI.m_BossInfoUI.Set(m_MonsterTableData.Get_Name()); } @@ -87,6 +88,12 @@ public class MobActor : Actor InGameInfo.Ins.Show_Effect("Effect_MonsterSpawn", pos); //GameUI.Ins.IngameUI.m_ChapterQuest.Add_PurposeCount(new ChapterQuestAddData { purpose = ePurpose.MeetMob, mobid = m_MonsterTableData.n_MonsterID }); } + public void Set(int iteration, bool isFirstAttack, float chaseRange) + { + b_IsFirstAttack = isFirstAttack; + f_BaseChaseRange *= chaseRange; + m_Stat.Set_Wave(iteration); + } public override void On_Regen() { base.On_Regen(); @@ -254,7 +261,7 @@ public class MobActor : Actor { if (b_IsFirstAttack) { // 선공이고, 플레이어가 추적 범위 안에 들어오면 전투 상태로 전환 - var enemies = ActorInfo.Ins.Get_EnemyActors(IsEnemy(), Get_position(), m_MonsterTableData.f_BaseChaseRange); + var enemies = ActorInfo.Ins.Get_EnemyActors(IsEnemy(), Get_position(), f_BaseChaseRange); if (enemies.Count > 0) Change_MobStatus(eMobStatus.Battle); } diff --git a/Assets/Script/Info/DungeonInfo.cs b/Assets/Script/Info/DungeonInfo.cs index c5ee0fb71..39d2aecc0 100644 --- a/Assets/Script/Info/DungeonInfo.cs +++ b/Assets/Script/Info/DungeonInfo.cs @@ -115,16 +115,18 @@ public class DungeonInfo : MonoBehaviourSingletonTemplate } } } - void Make_Mob(eSubRol subrol, MonsterTableData mobData, DungeonMapConfigTableData dgData, float minDist, float MaxDist) + void Make_Mob(eSubRol subrol, MonsterTableData mobData, DungeonMapConfigTableData dgData, Vector3 makepos, + float minDist, float MaxDist, Action act = null) { AddrResourceMgr.Ins.LoadObject(mobData.s_MonsterPrefab, handle => { var mob = DSUtil.Get_Clone(handle.Result); ActorInfo.Ins.Add_Actor(mob, eRole.Mob, dgData.n_SpawnID, mobData.s_MonsterPrefab); mob.Set(true, null, null, dgData.n_SpawnID, false); - var rdnpos = DSUtil.Get_RandomPos_onNavMesh(MyValue.MyPC.Get_position(), minDist, MaxDist); + var rdnpos = DSUtil.Get_RandomPos_onNavMesh(makepos, minDist, MaxDist); mob.Set(mobData, rdnpos, Set_MobDie, 0); mob.m_SubRole = subrol; + act?.Invoke(mob); }); } @@ -145,7 +147,7 @@ public class DungeonInfo : MonoBehaviourSingletonTemplate case eDungeon.d1_Mimic: StartCoroutine(Co_Update_Mimic()); break; case eDungeon.d2_Maze: StartCoroutine(Co_Update_Maze()); break; case eDungeon.d3_Nightmare: StartCoroutine(Co_Update_Nightmare()); break; - case eDungeon.d4_Wave: break; + case eDungeon.d4_Wave: StartCoroutine(Co_Update_Wave()); break; } } IEnumerator Co_Update_Mimic() @@ -161,7 +163,7 @@ public class DungeonInfo : MonoBehaviourSingletonTemplate while (mobCount > 0) { --mobCount; - Make_Mob(eSubRol.Mimic, mimicData, dungeonData, min, max); + Make_Mob(eSubRol.Mimic, mimicData, dungeonData, MyValue.MyPC.Get_position(), min, max); yield return new WaitForSeconds(dungeonData.f_MakeGap); } } @@ -171,12 +173,12 @@ public class DungeonInfo : MonoBehaviourSingletonTemplate float min = 10f, max = 20f; var dgData = MyValue.MyChoiceMapData.Get_DungeonMapData_orNull(); for (int i = 0; i < dgData.n_MobCount; i++) - Make_Mob(eSubRol.None, table_monsterlist.Ins.Get_RandomData(eSubRol.None), dgData, min, max); + Make_Mob(eSubRol.None, table_monsterlist.Ins.Get_RandomData(eSubRol.None), dgData, MyValue.MyPC.Get_position(), min, max); if (m_MazeClear >= 5) { m_MazeClear = 0; - Make_Mob(eSubRol.Boss, table_monsterlist.Ins.Get_RandomData(eSubRol.Boss), dgData, min, max); + Make_Mob(eSubRol.Boss, table_monsterlist.Ins.Get_RandomData(eSubRol.Boss), dgData, MyValue.MyPC.Get_position(), min, max); } yield return new WaitForSeconds(1f); @@ -198,7 +200,8 @@ public class DungeonInfo : MonoBehaviourSingletonTemplate var dgData = MyValue.MyChoiceMapData.Get_DungeonMapData_orNull(); for (int i = 0; i < dgData.n_MobCount; i++) { - Make_Mob(eSubRol.Boss, table_monsterlist.Ins.Get_RandomData(eSubRol.Boss), dgData, 10, 25); + var boss = table_monsterlist.Ins.Get_RandomData(eSubRol.Boss); + Make_Mob(eSubRol.Boss, boss, dgData, MyValue.MyPC.Get_position(), 10, 25); yield return new WaitForSeconds(30f); } } @@ -213,6 +216,31 @@ public class DungeonInfo : MonoBehaviourSingletonTemplate act_DamageUI?.Invoke(m_TotalDamage); } + IEnumerator Co_Update_Wave() + { + yield return new WaitForSeconds(1f); + StartCoroutine(Co_Update_Time()); + + float min = 0f, max = 15f; + var mapdata = MyValue.MyChoiceMapData.Get_MapData(); + var dungeonData = MyValue.MyChoiceMapData.Get_DungeonMapData_orNull(); + int iteration = 0; + while (true) + { + var mobCount = dungeonData.n_MobCount; + while (mobCount > 0) + { + --mobCount; + var mobData = table_monsterlist.Ins.Get_RandomData(eSubRol.None); + Make_Mob(eSubRol.None, mobData, dungeonData, Vector3.zero, min, max, + mob => { mob.Set(iteration, true, 25f); }); + yield return new WaitForSeconds(0.5f); + } + + yield return new WaitForSeconds(dungeonData.f_MakeGap); + ++iteration; + } + } public void Set_Wave(Action actscoreui, Action actlifeui) { WaveScore = 0; diff --git a/Assets/Script/Table/Dungeon/table_dungeonmapconfig.cs b/Assets/Script/Table/Dungeon/table_dungeonmapconfig.cs index ef5385392..1953fbd54 100644 --- a/Assets/Script/Table/Dungeon/table_dungeonmapconfig.cs +++ b/Assets/Script/Table/Dungeon/table_dungeonmapconfig.cs @@ -49,6 +49,13 @@ public class DungeonMapConfigTableData : TableDataBase set { _Time = value; _Time.RandomizeCryptoKey(); } } + protected ObscuredFloat _Increase; + public float f_Increase + { + get { return _Increase; } + set { _Increase = value; _Increase.RandomizeCryptoKey(); } + } + public int Get_DungeonIndex() { return MyEnumToInt.Ins.Get_Int(e_DungeonType) - 1; } } diff --git a/Assets/Script/Util/MyValue.cs b/Assets/Script/Util/MyValue.cs index 516d4d710..1c695652f 100644 --- a/Assets/Script/Util/MyValue.cs +++ b/Assets/Script/Util/MyValue.cs @@ -952,11 +952,27 @@ public class ActorStatInfo var keys = dic_StatValue.Keys.ToList(); foreach (var key in keys) { - dic_StatValue[key] += dic_StatValue[key] * (lv * 0.5d); + dic_StatValue[key] += dic_StatValue[key] * (lv * MyValue.MyChoiceMapData.Get_DungeonMapData_orNull().f_Increase); dic_StatValue[key].RandomizeCryptoKey(); } } } + public void Set_Wave(int iteration) + { + if (MyValue.MyChoiceMapData.Get_MapData().e_Dungeon == eDungeon.d4_Wave) + { + var keys = dic_StatValue.Keys.ToList(); + foreach (var key in keys) + { + //if (key == eStat.BaseDmg && iteration > 0) + // Debug.Log($"전 {iteration} : {dic_StatValue[key]}"); + dic_StatValue[key] += dic_StatValue[key] * (iteration * MyValue.MyChoiceMapData.Get_DungeonMapData_orNull().f_Increase); + dic_StatValue[key].RandomizeCryptoKey(); + //if (key == eStat.BaseDmg && iteration > 0) + // Debug.Log($"후 {iteration} : {dic_StatValue[key]}"); + } + } + } public double Get_Stat(eStat key, int idkey = 0) {