lzx 1 周之前
父節點
當前提交
131e8bfe83

+ 2 - 1
Assets/Scripts/GameUI/Editor/GameUIEditor.asmdef

@@ -8,7 +8,8 @@
         "Kybernetik.Animancer",
         "Fort23.GameLogic",
         "Unity.Timeline",
-        "Fort23.Mono"
+        "Fort23.Mono",
+        "Fort23.GameData"
     ],
     "includePlatforms": [
         "Editor"

+ 9 - 0
Assets/Scripts/GameUI/Editor/PlayerDataEditorWindow.cs

@@ -6,6 +6,7 @@ using System.Collections.Generic;
 using System;
 using System.Collections;
 using System.IO;
+using Excel2Json;
 using Fort23.UTool;
 
 public class PlayerDataEditorWindow : EditorWindow
@@ -65,6 +66,14 @@ public class PlayerDataEditorWindow : EditorWindow
             {
                 if (int.TryParse(targetFolder, out int eventid))
                 {
+                    EventConfig eventConfig = ConfigComponent.Instance.Get<EventConfig>(eventid);
+                    
+                    if (eventConfig.EventTriggerType == 4 || eventConfig.EventTriggerType == 6)
+                    {
+                        AccountFileInfo.Instance.playerData.eventList.RemoveAll(e => e.eventID == eventid);
+                    }
+
+
                     var eventList = EventSystemManager.Instance.AddEvent(eventid);
 
                     if (eventList != null)