12345678910111213141516171819202122232425262728293031323334353637 |
- using FairyGUI;
- using Sirenix.Utilities;
- namespace ET.Client
- {
- [Event(SceneType.Client)]
- public class LoginFinish_RemoveLoginUI: AEvent<EventType.LoginFinish>
- {
- protected override async ETTask Run(Scene scene, EventType.LoginFinish args)
- {
- if(!args.exeception.IsNullOrWhitespace())
- {
- var loginview = GRoot.inst.GetChild("Login");
- if(loginview != null)
- {
- var component = loginview.asCom;
- var tips = component.GetChild("txt_tips");
- tips.visible = true;
- tips.text = "连接服务器过程中出现了问题\n" +
- "如重试后还是不行,请与客服联系" +
- "\n[color=#FFCCCC][b]QQ: 400888666[/b][/color] 微信:[color=#FFCCCC][b]大老板[/color][/b]";
- component.GetChild("img_tips").visible = false;
- component.GetChild("Btn_Login").enabled = true;
- }
- else
- {
- Log.Error("not found login view @login error");
- }
- return;
- }
- await TimerComponent.Instance.WaitAsync(1000);
- GRoot.inst.RemoveChildAt(0, true);
- UIPackage.RemovePackage("Login");
- }
- }
- }
|