| 
					
				 | 
			
			
				@@ -23,7 +23,7 @@ namespace GFGGame 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             ViewManager.Show<ModalStatusView>("登录中..."); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             int errorCode = await ET.LoginHelper.Login(GameGlobal.zoneScene, ET.ConstValue.LoginAddress, account, password, isMD5); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-            ViewManager.Hide<ModalStatusView>(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+             
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             if (errorCode == ET.ErrorCode.ERR_Success) 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                 GameGlobal.isVisitor = false; 
			 | 
		
	
	
		
			
				| 
					
				 | 
			
			
				@@ -55,6 +55,7 @@ namespace GFGGame 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             else 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                ViewManager.Hide<ModalStatusView>(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                 if (ErrorCodeController.Handler(errorCode)) 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                 { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                     ViewManager.Show<LoginInputView>(); 
			 | 
		
	
	
		
			
				| 
					
				 | 
			
			
				@@ -62,17 +63,23 @@ namespace GFGGame 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				  
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        public static void Logout() 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            GameGlobal.zoneScene.GetComponent<SessionComponent>().Session?.Dispose(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         public static async ETTask Register(string account, string password, string name, string identityNum, string code) 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             ViewManager.Show<ModalStatusView>("注册中..."); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             int errorCode = await LoginHelper.Register(GameGlobal.zoneScene, ET.ConstValue.LoginAddress, account, password, name, identityNum, code); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-            ViewManager.Hide<ModalStatusView>(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+             
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             if (errorCode == ErrorCode.ERR_Success) 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                 Login(account, password).Coroutine(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             else 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                ViewManager.Hide<ModalStatusView>(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                 ErrorCodeController.Handler(errorCode); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         } 
			 | 
		
	
	
		
			
				| 
					
				 | 
			
			
				@@ -118,15 +125,18 @@ namespace GFGGame 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             else 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                ViewManager.Hide<ModalStatusView>(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                 GameController.ShowCreateRole(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				  
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         public static async ETTask ReqCreateRole(string roleName) 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            ViewManager.Show<ModalStatusView>("创建角色中..."); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             int errorCode = await ET.LoginHelper.CreateRole(GameGlobal.zoneScene, roleName); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             if (errorCode != ErrorCode.ERR_Success) 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                ViewManager.Hide<ModalStatusView>(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                 ErrorCodeController.Handler(errorCode); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                 return; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             } 
			 | 
		
	
	
		
			
				| 
					
				 | 
			
			
				@@ -157,6 +167,7 @@ namespace GFGGame 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                 return; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             await GameController.PreEnterGameAsync(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            ViewManager.Hide<ModalStatusView>(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				     } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 } 
			 |