Эх сурвалжийг харах

Merge branch 'master' of http://git.gfggame.com:3000/gfg/client

# Conflicts:
#	FGUIProject/assets/Main/componentsLevel/CompChapter10001.xml
#	GameClient/Assets/ResIn/UI/Main/Main_fui.bytes
zhaoyang 3 жил өмнө
parent
commit
8c362f67e9

+ 1 - 0
FGUIProject/assets/CommonGame/package.xml

@@ -189,6 +189,7 @@
     <image id="slyzthy" name="yx_yihd.png" path="/images/"/>
     <image id="hibuthz" name="fb_gongzuos.png" path="/imgItemIcon/" exported="true"/>
     <component id="pjip15" name="SuitPartsDetailUI.xml" path="/" exported="true"/>
+    <image id="gd29ti0" name="jingzhongh_bg.jpg" path="/bgimg/"/>
   </resources>
   <publish name="" path="..\GameClient\Assets\ResIn\UI\CommonGame" packageCount="2" genCode="true" extractAlpha="true"/>
 </packageDescription>

+ 2 - 2
FGUIProject/assets/Main/componentsLevel/CompChapter20001.xml

@@ -1,9 +1,9 @@
 <?xml version="1.0" encoding="utf-8"?>
 <component size="1200,2600" scroll="both">
   <displayList>
-    <image id="n37_fz8v" name="loaBg" src="hky3fc" fileName="imagesStory/beijing0_bg.jpg" xy="600,1300" pivot="0.5,0.5" anchor="true" size="1200,2600">
+    <loader id="n37_fz8v" name="loaBg" xy="600,1300" pivot="0.5,0.5" anchor="true" size="1200,2600" fill="scaleMatchWidth">
       <relation target="" sidePair="width-width,height-height,center-center,middle-middle"/>
-    </image>
+    </loader>
     <component id="n31_oq7r" name="g1" src="xuzk2d" fileName="componentsLevel/CompStoryLevelItem.xml" xy="509,1972"/>
     <component id="n32_oq7r" name="g2" src="xuzk2d" fileName="componentsLevel/CompStoryLevelItem.xml" xy="639,1655"/>
     <component id="n33_oq7r" name="g3" src="xuzk2d" fileName="componentsLevel/CompStoryLevelItem.xml" xy="411,1425"/>

+ 0 - 5
FGUIProject/assets/Main/package.xml

@@ -341,7 +341,6 @@
     <component id="lki4db" name="ComRoleSkill1.xml" path="/components/"/>
     <component id="txgzdc" name="CompChapter10002.xml" path="/componentsLevel/" exported="true"/>
     <component id="txgzdd" name="CompChapter10001.xml" path="/componentsLevel/" exported="true"/>
-    <image id="n1knde" name="beijing2_bg.jpg" path="/imagesStory/" atlas="alone_npot"/>
     <image id="jj0mdf" name="zd_jsjs_2.png" path="/images/"/>
     <image id="jj0mdg" name="zd_jsjs_1.png" path="/images/"/>
     <component id="jj0mdl" name="ButtonSpeedUp1.xml" path="/componentsDialog/"/>
@@ -381,11 +380,7 @@
     <movieclip id="wet2f3" name="MovieClip4.jta" path="/Movie/"/>
     <image id="ox5bf4" name="zjm_hdhd_3.png" path="/images/"/>
     <component id="ox5bf5" name="Button2.xml" path="/components/"/>
-    <image id="eq0bf6" name="beijing1_bg.jpg" path="/imagesStory/" atlas="alone_npot"/>
-    <image id="eq0bf7" name="beijing3_bg.jpg" path="/imagesStory/" atlas="alone_npot"/>
-    <image id="eq0bf8" name="beijing4_bg.jpg" path="/imagesStory/" atlas="alone_npot"/>
     <image id="hky3fb" name="middle_img_v2_0c0211c4-7f8b-4e04-8f67-bc01ad27e8ag.png" path="/images/"/>
-    <image id="hky3fc" name="beijing0_bg.jpg" path="/imagesStory/" atlas="alone_npot"/>
   </resources>
   <publish name="" path="..\GameClient\Assets\ResIn\UI\Main" packageCount="2" genCode="true" extractAlpha="true"/>
 </packageDescription>

+ 6 - 2
GameClient/Assets/Game/HotUpdate/Controller/LoginController.cs

@@ -98,8 +98,8 @@ namespace GFGGame
         }
         private static async ETTask ReqNoticeInfo()
         {
-            bool result = await LoginHelper.ReqGetLatestNotice();
-            if (result)
+            int result = await LoginHelper.ReqGetLatestNotice();
+            if (result == ErrorCode.ERR_Success)
             {
                 NoticeInfo noticeInfo = NoticeDataManager.Instance.LastNoticeInfo;
                 Debug.Log("noticeTime:" + noticeInfo.time + "  currentTime:" + (TimeInfo.Instance.ServerNow() / 1000));
@@ -112,6 +112,10 @@ namespace GFGGame
                     ViewManager.Show<SystemNoticeView>(new object[] { NoticeDataManager.Instance.LastNoticeInfo.title, NoticeDataManager.Instance.LastNoticeInfo.content });
                 }
             }
+            else
+            {
+                ErrorCodeController.Handler(result);
+            }
             return;
         }
 

+ 28 - 28
GameClient/Assets/Game/HotUpdate/ETCodes/Hotfix/App/Login/LoginHelper.cs

@@ -21,7 +21,7 @@ namespace ET
             catch (Exception e)
             {
                 accountSession?.Dispose();
-                Log.Error(e.ToString());
+                //Log.Debug(e.ToString());
                 return ErrorCode.ERR_NetWorkError;
             }
 
@@ -57,7 +57,7 @@ namespace ET
             catch (Exception e)
             {
                 accountSession?.Dispose();
-                Log.Error(e.ToString());
+                //Log.Error(e.ToString());
                 return ErrorCode.ERR_NetWorkError;
             }
 
@@ -105,7 +105,7 @@ namespace ET
             catch (Exception e)
             {
                 session?.Dispose();
-                Log.Error(e.ToString());
+                //Log.Error(e.ToString());
                 return ErrorCode.ERR_NetWorkError;
             }
             return ErrorCode.ERR_Success;
@@ -125,7 +125,7 @@ namespace ET
             }
             catch (Exception e)
             {
-                Log.Error(e.ToString());
+                //Log.Error(e.ToString());
                 return ErrorCode.ERR_NetWorkError;
             }
 
@@ -161,13 +161,13 @@ namespace ET
             }
             catch (Exception e)
             {
-                Log.Error(e.ToString());
+                //Log.Error(e.ToString());
                 return ErrorCode.ERR_NetWorkError;
             }
 
             if (a2C_GetRoles.Error != ErrorCode.ERR_Success)
             {
-                Log.Error(a2C_GetRoles.Error.ToString());
+                //Log.Error(a2C_GetRoles.Error.ToString());
                 return a2C_GetRoles.Error;
             }
 
@@ -197,13 +197,13 @@ namespace ET
             }
             catch (Exception e)
             {
-                Log.Error(e.ToString());
+                //Log.Error(e.ToString());
                 return ErrorCode.ERR_NetWorkError;
             }
 
             if (a2C_CreateRole.Error != ErrorCode.ERR_Success)
             {
-                Log.Error(a2C_CreateRole.Error.ToString());
+                //Log.Error(a2C_CreateRole.Error.ToString());
                 return a2C_CreateRole.Error;
             }
 
@@ -230,13 +230,13 @@ namespace ET
             }
             catch (Exception e)
             {
-                Log.Error(e.ToString());
+                //Log.Error(e.ToString());
                 return ErrorCode.ERR_NetWorkError;
             }
 
             if (a2C_DeleteRole.Error != ErrorCode.ERR_Success)
             {
-                Log.Error(a2C_DeleteRole.Error.ToString());
+                //Log.Error(a2C_DeleteRole.Error.ToString());
                 return a2C_DeleteRole.Error;
             }
 
@@ -262,13 +262,13 @@ namespace ET
             }
             catch (Exception e)
             {
-                Log.Error(e.ToString());
+                //Log.Error(e.ToString());
                 return ErrorCode.ERR_NetWorkError;
             }
 
             if (a2C_GetRealmKey.Error != ErrorCode.ERR_Success)
             {
-                Log.Error(a2C_GetRealmKey.Error.ToString());
+                //Log.Error(a2C_GetRealmKey.Error.ToString());
                 return a2C_GetRealmKey.Error;
             }
 
@@ -297,7 +297,7 @@ namespace ET
             }
             catch (Exception e)
             {
-                Log.Error(e);
+                //Log.Error(e);
                 session?.Dispose();
                 return ErrorCode.ERR_NetWorkError;
             }
@@ -329,7 +329,7 @@ namespace ET
             }
             catch (Exception e)
             {
-                Log.Error(e);
+                //Log.Error(e);
                 zoneScene.GetComponent<SessionComponent>().Session?.Dispose();
                 return ErrorCode.ERR_NetWorkError;
             }
@@ -350,14 +350,14 @@ namespace ET
             }
             catch (Exception e)
             {
-                Log.Error(e);
+                //Log.Error(e);
                 zoneScene.GetComponent<SessionComponent>().Session.Dispose();
                 return ErrorCode.ERR_NetWorkError;
             }
 
             if (g2C_EnterGame.Error != ErrorCode.ERR_Success)
             {
-                Log.Error(g2C_EnterGame.Error.ToString());
+                //Log.Error(g2C_EnterGame.Error.ToString());
                 return g2C_EnterGame.Error;
             }
 
@@ -369,7 +369,7 @@ namespace ET
             return ErrorCode.ERR_Success;
         }
 
-        public static async ETTask<bool> ReqGetLatestNotice()
+        public static async ETTask<int> ReqGetLatestNotice()
         {
             A2C_GetLatestNotice response = null;
             try
@@ -378,14 +378,14 @@ namespace ET
             }
             catch (Exception e)
             {
-                Log.Error(e.ToString());
-                return false;
+                //Log.Error(e.ToString());
+                return ErrorCode.ERR_NetWorkError;
             }
 
             if (response.Error != ErrorCode.ERR_Success)
             {
-                Log.Error(response.Error.ToString());
-                return false;
+                //Log.Error(response.Error.ToString());
+                return response.Error;
             }
             NoticeInfo noticeInfo = new NoticeInfo();
             noticeInfo.noticeId = response.NoticeId;
@@ -395,9 +395,9 @@ namespace ET
 
             NoticeDataManager.Instance.LastNoticeInfo = noticeInfo;
 
-            return true;
+            return ErrorCode.ERR_Success;
         }
-        public static async ETTask<string> ReqRandomRoleName()
+        public static async ETTask<(int, string)> ReqRandomRoleName()
         {
             A2C_GetRandomRoleName response = null;
             try
@@ -406,17 +406,17 @@ namespace ET
             }
             catch (Exception e)
             {
-                Log.Error(e.ToString());
-                return "";
+                //Log.Error(e.ToString());
+                return (ErrorCode.ERR_NetWorkError, "");
             }
 
             if (response.Error != ErrorCode.ERR_Success)
             {
-                Log.Error(response.Error.ToString());
-                return "";
+                //Log.Error(response.Error.ToString());
+                return (ErrorCode.ERR_NetWorkError, "");
             }
 
-            return response.Name;
+            return (ErrorCode.ERR_Success, response.Name);
         }
     }
 }

+ 4 - 4
GameClient/Assets/Game/HotUpdate/ETCodes/Hotfix/App/Numeric/NumericHelper.cs

@@ -13,13 +13,13 @@ namespace ET
             }
             catch(System.Exception e)
             {
-                Log.Error(e.ToString());
+                //Log.Error(e.ToString());
                 return ErrorCode.ERR_NetWorkError;
             }
 
             if(m2C_TestUnitNumric.Error != ErrorCode.ERR_Success)
             {
-                Log.Error(m2C_TestUnitNumric.Error.ToString());
+                //Log.Error(m2C_TestUnitNumric.Error.ToString());
                 return m2C_TestUnitNumric.Error;
             }
 
@@ -35,12 +35,12 @@ namespace ET
             }
             catch(Exception e)
             {
-                Log.Error(e.ToString());
+                //Log.Error(e.ToString());
                 return ErrorCode.ERR_NetWorkError;
             }
             if(m2C_AddAttributePoint.Error != ErrorCode.ERR_Success)
             {
-                Log.Error(m2C_AddAttributePoint.Error.ToString());
+                //Log.Error(m2C_AddAttributePoint.Error.ToString());
                 return m2C_AddAttributePoint.Error;
             }
             return ErrorCode.ERR_Success;

+ 2 - 2
GameClient/Assets/Game/HotUpdate/FairyGUI/GenCode/Main/UI_CompChapter20001.cs

@@ -7,7 +7,7 @@ namespace UI.Main
     public partial class UI_CompChapter20001
     {
         public GComponent target;
-        public GImage m_loaBg;
+        public GLoader m_loaBg;
         public UI_CompStoryLevelItem m_g1;
         public UI_CompStoryLevelItem m_g2;
         public UI_CompStoryLevelItem m_g3;
@@ -61,7 +61,7 @@ namespace UI.Main
 
         private void Init(GComponent comp)
         {
-            m_loaBg = (GImage)comp.GetChild("loaBg");
+            m_loaBg = (GLoader)comp.GetChild("loaBg");
             m_g1 = (UI_CompStoryLevelItem)UI_CompStoryLevelItem.Create(comp.GetChild("g1"));
             m_g2 = (UI_CompStoryLevelItem)UI_CompStoryLevelItem.Create(comp.GetChild("g2"));
             m_g3 = (UI_CompStoryLevelItem)UI_CompStoryLevelItem.Create(comp.GetChild("g3"));

+ 9 - 3
GameClient/Assets/Game/HotUpdate/Views/CreateRole/CreateRoleView.cs

@@ -69,9 +69,15 @@ namespace GFGGame
 
         private async void RandomRoleName()
         {
-            string name = await LoginHelper.ReqRandomRoleName();
-
-            _ui.m_inputName.text = name;
+            (int result,string name) = await LoginHelper.ReqRandomRoleName();
+            if(result == ErrorCode.ERR_Success)
+            {
+                _ui.m_inputName.text = name;
+            }
+            else
+            {
+                ErrorCodeController.Handler(result);
+            }
         }
 
     }

BIN
GameClient/Assets/ResIn/Config/excelConfig.sqlite.bytes