少年修仙传客户端代码仓库
1652 从wifi状态下,切换到4g后,游戏重连回到登入界面,但是不能点击【进入游戏】
1个文件已修改
63 ■■■■■ 已修改文件
System/Login/LoginModel.cs 63 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
System/Login/LoginModel.cs
@@ -15,8 +15,7 @@
        public SDKUtility.FP_LoginOk sdkLoginResult;
        public SDKUtility.FP_CheckIDAuthentication sdkIDCheckIDAuthentication;
        public string localSaveAccountName
        {
        public string localSaveAccountName {
            get { return LocalSave.GetString(USER_ACCOUNT); }
            set { LocalSave.SetString(USER_ACCOUNT, value); }
        }
@@ -25,22 +24,19 @@
        public event Action accountBindOkEvent;
        bool m_ReconnecBackGround = false;
        public bool reconnectBackGround
        {
        public bool reconnectBackGround {
            get { return m_ReconnecBackGround; }
            set { m_ReconnecBackGround = value; }
        }
        bool m_OnCreateRole = false;
        public bool onCreateRole
        {
        public bool onCreateRole {
            get { return m_OnCreateRole; }
            set { m_OnCreateRole = value; }
        }
        bool m_Busy = false;
        public bool busy
        {
        public bool busy {
            get { return m_Busy; }
            set { m_Busy = value; }
        }
@@ -144,17 +140,27 @@
            }
            busy = true;
            reconnectBackGround = false;
            accountBuf = _account;
            localSaveAccountName = accountBuf;
            ipBuf = _ip;
            portBuf = _port;
            gamePortBuf = _gamePort;
            ConnectGameServer(ipBuf, gamePortBuf);
            try
            {
                reconnectBackGround = false;
                accountBuf = _account;
                localSaveAccountName = accountBuf;
                ipBuf = _ip;
                portBuf = _port;
                gamePortBuf = _gamePort;
            GameNetSystem.Instance.OnAccountLogin();
            NetLinkWin.Show();
                ConnectGameServer(ipBuf, gamePortBuf);
                GameNetSystem.Instance.OnAccountLogin();
                NetLinkWin.Show();
            }
            catch (Exception ex)
            {
                Debug.Log(ex);
                busy = false;
            }
        }
        public void AccountLogin(string _ip, int _port, int _gamePort)
@@ -175,9 +181,16 @@
            busy = true;
            reconnectBackGround = true;
            ConnectGameServer(ipBuf, gamePortBuf);
            NetLinkWin.Show();
            try
            {
                ConnectGameServer(ipBuf, gamePortBuf);
                NetLinkWin.Show();
            }
            catch (Exception ex)
            {
                Debug.Log(ex);
                busy = false;
            }
        }
        private void OnAccountLogin(bool _ok, string _result)
@@ -212,7 +225,15 @@
            }
            localSaveAccountName = accountBuf;
            ConnectGameServer(ipBuf, gamePortBuf);
            try
            {
                ConnectGameServer(ipBuf, gamePortBuf);
            }
            catch (Exception ex)
            {
                busy = false;
                Debug.Log(ex);
            }
        }
        void ConnectGameServer(string _ip, int _port)