From 5011ab26850a90b797b50278ce966e88bc97acf8 Mon Sep 17 00:00:00 2001 From: 45 <980269297@qq.com> Date: Thu, 15 May 2025 19:00:42 +0800 Subject: [PATCH] =?UTF-8?q?=E6=B5=81=E7=A8=8B=E5=AE=8C=E5=96=840515?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Assets/GameDate/PotionList.asset | 3 +-- .../Assets/GameDate/cardDeckList.asset | 27 ++++++++----------- .../Assets/Scenes/CampPoint.unity | 2 +- .../Assets/Scripts/Enemy/Thief.cs | 4 +-- .../Scripts/LeveProcess/LeveGeneraterNew.cs | 4 +-- .../Assets/Scripts/LeveProcess/LevelNode.cs | 24 ++++++++++++++--- .../Assets/Scripts/Relic/LegacyNode.cs | 5 +++- .../Scripts/manager/EnemyPlanUIManager.cs | 3 ++- 8 files changed, 44 insertions(+), 28 deletions(-) diff --git a/ColorlessWorld-2024-4-2/Assets/GameDate/PotionList.asset b/ColorlessWorld-2024-4-2/Assets/GameDate/PotionList.asset index 0eb69ee1..af3515c5 100644 --- a/ColorlessWorld-2024-4-2/Assets/GameDate/PotionList.asset +++ b/ColorlessWorld-2024-4-2/Assets/GameDate/PotionList.asset @@ -12,5 +12,4 @@ MonoBehaviour: m_Script: {fileID: 11500000, guid: 4220f07a4a8a6784ebec6e8f07eb81ef, type: 3} m_Name: PotionList m_EditorClassIdentifier: - potionList: - - 1 + potionList: [] diff --git a/ColorlessWorld-2024-4-2/Assets/GameDate/cardDeckList.asset b/ColorlessWorld-2024-4-2/Assets/GameDate/cardDeckList.asset index 465b0875..83ba3b4b 100644 --- a/ColorlessWorld-2024-4-2/Assets/GameDate/cardDeckList.asset +++ b/ColorlessWorld-2024-4-2/Assets/GameDate/cardDeckList.asset @@ -13,19 +13,14 @@ MonoBehaviour: m_Name: cardDeckList m_EditorClassIdentifier: cardDeckList: - - 1010 - - 1005 - - 1010 - - 1010 - - 2040 - - 2041 - - 2042 - - 2043 - - 2044 - - 2045 - - 2046 - - 2047 - - 1010 - - 1010 - - 1005 - - 1005 + - 1001 + - 1001 + - 1001 + - 1002 + - 1002 + - 1002 + - 1003 + - 1003 + - 2032 + - 2001 + - 2019 diff --git a/ColorlessWorld-2024-4-2/Assets/Scenes/CampPoint.unity b/ColorlessWorld-2024-4-2/Assets/Scenes/CampPoint.unity index 58067f4d..3a57b4f8 100644 --- a/ColorlessWorld-2024-4-2/Assets/Scenes/CampPoint.unity +++ b/ColorlessWorld-2024-4-2/Assets/Scenes/CampPoint.unity @@ -7888,7 +7888,7 @@ MonoBehaviour: m_Script: {fileID: 11500000, guid: 7fdb8517729ce2b42b8193e7b887c770, type: 3} m_Name: m_EditorClassIdentifier: - gameObjectUI: {fileID: 0} + gameObjectUI: {fileID: 1463029924} --- !u!114 &570399559 MonoBehaviour: m_ObjectHideFlags: 0 diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Enemy/Thief.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Enemy/Thief.cs index c50d1a09..69a0b29d 100644 --- a/ColorlessWorld-2024-4-2/Assets/Scripts/Enemy/Thief.cs +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Enemy/Thief.cs @@ -49,8 +49,8 @@ public class Thief : Enemy { if (aliveCount >= 3) { - enemyNode.currentActionScript = EnemyPlanUIManager.enemyPlanUIIconDictionary[EnemyPlanUIFunction.nothing].NewAction(); - enemyAction = EnemyPlanUIManager.enemyPlanUIIconDictionary[EnemyPlanUIFunction.nothing].NewAction(); + enemyNode.currentActionScript = EnemyPlanUIManager.Instance.enemyPlanUIIconDictionary[EnemyPlanUIFunction.nothing].NewAction(); + enemyAction = EnemyPlanUIManager.Instance.enemyPlanUIIconDictionary[EnemyPlanUIFunction.nothing].NewAction(); enemyNode.enemyUIBar.SwitchIntention(enemyAction); enemyNode.enemyUIBar.outAttackRange.SetActive(false); } diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/LeveProcess/LeveGeneraterNew.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/LeveProcess/LeveGeneraterNew.cs index 1cf7fb9c..3dcaab95 100644 --- a/ColorlessWorld-2024-4-2/Assets/Scripts/LeveProcess/LeveGeneraterNew.cs +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/LeveProcess/LeveGeneraterNew.cs @@ -758,12 +758,12 @@ public class LeveGeneraterNew : Singleton } //判断能否进入 - int line = LevelDevelopManager.Instance.levelDevelopData.levelStep; + /* int line = LevelDevelopManager.Instance.levelDevelopData.levelStep; for (int j = 0; j < LevelDevelopManager.Instance.levelMap[line].levelColumn.Count; j++) { LevelNode currentLevelNode = LevelDevelopManager.Instance.levelMap[line].levelColumn[j]; currentLevelNode.JudgeRoadCanEnter(); - } + }*/ } //设置房间怪物组和地图 diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/LeveProcess/LevelNode.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/LeveProcess/LevelNode.cs index 917a34d4..81778866 100644 --- a/ColorlessWorld-2024-4-2/Assets/Scripts/LeveProcess/LevelNode.cs +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/LeveProcess/LevelNode.cs @@ -120,9 +120,27 @@ public class LevelNode : MonoBehaviour } else { - canEnter = true; - roomIcon.color = new Color(1, 1, 1, 1f); - + bool isNextNode = false; + List nextNodes = PlayerStatsManager.Instance.levelDevelopData.levelSaveMap[(int)PlayerStatsManager.Instance.levelDevelopData.currentPoint.x].levelDataList[(int)PlayerStatsManager.Instance.levelDevelopData.currentPoint.y].nextLevelNodes; + foreach (var node in nextNodes) + { + if((int)node.x == line &&(int)node .y ==column) + { + + isNextNode = true; + break; + } + } + if(isNextNode) + { + canEnter = true; + roomIcon.color = new Color(1, 1, 1, 1f); + } + else + { + canEnter = false; + roomIcon.color = new Color(1, 1, 1, 0.5f); + } } hightLightAnimator.SetBool("canEnter", canEnter); } diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/Relic/LegacyNode.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/Relic/LegacyNode.cs index 5226c050..be13f24d 100644 --- a/ColorlessWorld-2024-4-2/Assets/Scripts/Relic/LegacyNode.cs +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/Relic/LegacyNode.cs @@ -27,7 +27,10 @@ public class LegacyNode : MonoBehaviour relicClassName = relicData[1]; infor = relicData[4]; image = ToolDontDestory.Instance.LoadImage(relicData[2]); - LegacyManager.Instance.legacyNodesList.Add(relicName,this); + if (LegacyManager.Instance.legacyNodesList.ContainsKey (className)==false ) + { + LegacyManager.Instance.legacyNodesList.Add(className, this); + } GetComponent().sprite = image; if (isOnGet ) { diff --git a/ColorlessWorld-2024-4-2/Assets/Scripts/manager/EnemyPlanUIManager.cs b/ColorlessWorld-2024-4-2/Assets/Scripts/manager/EnemyPlanUIManager.cs index e6a9c6b8..3077f121 100644 --- a/ColorlessWorld-2024-4-2/Assets/Scripts/manager/EnemyPlanUIManager.cs +++ b/ColorlessWorld-2024-4-2/Assets/Scripts/manager/EnemyPlanUIManager.cs @@ -5,7 +5,7 @@ using UnityEngine.UI; public class EnemyPlanUIManager : Singleton { - public static Dictionary enemyPlanUIIconDictionary = new Dictionary(); + public Dictionary enemyPlanUIIconDictionary = new Dictionary(); [Header("意图图标")] public Sprite attackIcon; @@ -52,6 +52,7 @@ public class EnemyPlanUIManager : Singleton public void AddEnemyPlanUIIcon(string enemyPlanUIFunction,EnemyAction enemyAction ,Sprite icon) { + Debug.Log("怪物ui" + enemyPlanUIIconDictionary.Count); enemyAction.sprite = icon; enemyPlanUIIconDictionary.Add(enemyPlanUIFunction, enemyAction); }