hexiaojie 9 месяцев назад
Родитель
Сommit
6702f105b7
1 измененных файлов с 1 добавлено и 21 удалено
  1. 1 21
      GameClient/Assets/Game/HotUpdate/UGUI/UGUIManager.cs

+ 1 - 21
GameClient/Assets/Game/HotUpdate/UGUI/UGUIManager.cs

@@ -20,27 +20,7 @@ namespace GFGGame
             {
                 Debug.Log($"正在初始化 canvas is null");
             }
-
-            var transform = canvas.transform;
-            if (transform == null)
-            {
-                Debug.Log($"正在初始化 transform is null");
-            }
-
-            var findDesktop = transform.Find("Desktop");
-            if (findDesktop == null)
-            {
-                // 打印所有子节点名称辅助调试
-                Debug.LogError($"未找到 Desktop 子节点!当前子节点列表:");
-                foreach (Transform child in canvas.transform)
-                {
-                    Debug.Log(child.name);
-                }
-
-                Debug.Log($"正在初始化 findDesktop is null");
-            }
-
-            desktop = findDesktop.gameObject;
+            
             Debug.Log($"正在初始化 DontDestroyOnLoad");
             GameObject.DontDestroyOnLoad(canvas);
             Debug.Log($"正在初始化 Init end");