hexiaojie 9 сар өмнө
parent
commit
b508ad2a89

+ 8 - 0
GameClient/Assets/Game/HotUpdate/Data/RoleInfoManager.cs

@@ -205,6 +205,12 @@ namespace GFGGame
         public void UpdateHead(GComponent component, int headId, int roleBorderId)
         {
             ItemCfg headCfg = ItemCfgArray.Instance.GetCfg(headId == 0 ? ConstItemID.HEADID : headId);
+            
+            if (headCfg == null)
+            {
+                headCfg = ItemCfgArray.Instance.GetCfg(ConstItemID.HEADID);
+            }
+            
             ItemCfg headBorderCfg = ItemCfgArray.Instance.GetCfg(roleBorderId == 0 ? ConstItemID.HEADBORDERID : roleBorderId);
 
             UI_ComHead comHead = UI_ComHead.Proxy(component);
@@ -223,6 +229,8 @@ namespace GFGGame
                 }
                 comHead.m_loaBorder.url = ResPathUtil.GetHeadBorderPath(headBorderCfg.res);
             }
+
+          
             comHead.m_comHead.m_loaIcon.url = ResPathUtil.GetHeadPath(headCfg.res);
             UI_ComHead.ProxyEnd();
         }