Skip to content

Commit 132bf89

Browse files
committed
[修复] 删除FairyGUI的适配库的报错处理
1 parent 2390f5e commit 132bf89

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

Assets/Hotfix/HotfixLauncher.cs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,9 @@
33
using Cysharp.Threading.Tasks;
44
using GameFrameX;
55
using GameFrameX.Event.Runtime;
6+
#if ENABLE_UI_FAIRYGUI
67
using GameFrameX.UI.FairyGUI.Runtime;
8+
#endif
79
using GameFrameX.Network.Runtime;
810
using Hotfix.Proto;
911
using SimpleJSON;

Assets/Hotfix/UI/Logic/UILogin/UIPlayerList.cs

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
11
using System;
22
using System.Collections.Generic;
33
using System.Net;
4-
using FairyGUI;
54
using GameFrameX.Event.Runtime;
65
using GameFrameX.Network.Runtime;
76
using GameFrameX.Runtime;
87
using GameFrameX.UI.Runtime;
98
#if ENABLE_UI_FAIRYGUI
9+
using FairyGUI;
1010
using GameFrameX.UI.FairyGUI.Runtime;
1111
#endif
1212
#if ENABLE_UI_UGUI
@@ -123,19 +123,17 @@ private async void OnPlayerListItemClick(object userData)
123123
m_right_Panel.gameObject.SetActive(true);
124124
}
125125
#endif
126+
#if ENABLE_UI_FAIRYGUI
126127
private void ItemRenderer(int index, GObject item)
127128
{
128129
var playerInfo = playerList[index];
129-
#if ENABLE_UI_FAIRYGUI
130130
var uiPlayerListItem = UIPlayerListItem.GetFormPool(item);
131131
uiPlayerListItem.m_level_text.text = "当前等级:" + playerInfo.Level.ToString();
132132
uiPlayerListItem.m_name_text.text = playerInfo.Name;
133133
uiPlayerListItem.m_icon.icon = UIPackage.GetItemURL(FUIPackage.UICommonAvatar, playerInfo.Avatar.ToString());
134-
#endif
135-
136134
item.data = playerInfo;
137135
}
138-
136+
#endif
139137
private static void OnNetworkClosed(object sender, GameEventArgs e)
140138
{
141139
Log.Info(nameof(OnNetworkClosed));

0 commit comments

Comments
 (0)