Browse Source

修改bug

lzx 1 week ago
parent
commit
9cb311a759
1 changed files with 26 additions and 22 deletions
  1. 26 22
      Assets/Scripts/GameUI/EventManager/EventSystemManager.cs

+ 26 - 22
Assets/Scripts/GameUI/EventManager/EventSystemManager.cs

@@ -1197,28 +1197,32 @@ public class EventSystemManager : Singleton<EventSystemManager>
         {
             for (var i = 0; i < eventConfig.PrizeIDs.Length; i++)
             {
-                DropConfig dropConfig = ConfigComponent.Instance.Get<DropConfig>(eventConfig.PrizeIDs[i]);
-                if (dropConfig.dropType == 3)
-                {
-                    if (eventConfig.PrizeNums[i] < 0)
-                    {
-                        List<ItemInfo> items =
-                            DropManager.Instance.Drop(dropConfig.dropGroupID[0], eventConfig.PrizeNums[i]);
-                        if (items != null)
-                            itemInfos.AddRange(items);
-                    }
-                    else
-                    {
-                        ItemInfo itemInfo = new ItemInfo(dropConfig.dropGroupID[0], eventConfig.PrizeNums[i]);
-                        itemInfos.Add(itemInfo);
-                    }
-                }
-                else
-                {
-                    List<ItemInfo> items = DropManager.Instance.DropItem(eventConfig.PrizeIDs[i]);
-                    if (items != null)
-                        itemInfos.AddRange(items);
-                }
+                List<ItemInfo> items =
+                    DropManager.Instance.Drop(eventConfig.PrizeIDs[i], eventConfig.PrizeNums[i]);
+                if (items != null)
+                    itemInfos.AddRange(items);
+                // DropConfig dropConfig = ConfigComponent.Instance.Get<DropConfig>(eventConfig.PrizeIDs[i]);
+                // if (dropConfig.dropType == 3)
+                // {
+                //     if (eventConfig.PrizeNums[i] < 0)
+                //     {
+                //         List<ItemInfo> items =
+                //             DropManager.Instance.Drop(dropConfig.dropGroupID[0], eventConfig.PrizeNums[i]);
+                //         if (items != null)
+                //             itemInfos.AddRange(items);
+                //     }
+                //     else
+                //     {
+                //         ItemInfo itemInfo = new ItemInfo(dropConfig.dropGroupID[0], eventConfig.PrizeNums[i]);
+                //         itemInfos.Add(itemInfo);
+                //     }
+                // }
+                // else
+                // {
+                //     List<ItemInfo> items = DropManager.Instance.DropItem(eventConfig.PrizeIDs[i]);
+                //     if (items != null)
+                //         itemInfos.AddRange(items);
+                // }
 
                 // itemInfos.Add(new ItemInfo(eventConfig.PrizeIDs[i], eventConfig.PrizeNums[i]));
             }