private IEnumerator WaitSendLogin() { LockPanel.Show("用戶:" + _inputFieldAccount.text + " 正在登陆游戏"); yield return(new WaitForSeconds(1.0f)); LoginModule.GetInstance().NetWork_Request_Login(_inputFieldAccount.text, ""); }
IEnumerator Start() { LoginModule.GetInstance().LoginPanel = this; LoginModule.GetInstance().CreateRolePanel = transform.parent.Find("UICreateRolePanel").GetComponent <UICreateRolePanel> (); _widget = Widget.Create(gameObject); _widget.BandingBtn_OnClick(OnBtnClick_Login, "ViewPort_Login/Btn_Login"); _widget.BandingBtn_OnClick(OnBtnClick_LoginWithOutNet, "ViewPort_Login/Btn_LoginWithOutNet"); _widget.BandingBtn_OnClick(OnBtnClick_SelectServerList, "ViewPort_Login/Group_CurServer/Btn_SelectServer"); _inputFieldAccount = _widget.GetComponent <InputField> ("ViewPort_Login/IF_Account/InputField"); _serverItem_Prefab = _widget.GetComponent <Transform> ("ViewPort_ServerList/Scroll View/Viewport/Content/ServerItem"); _txtCurServerName = _widget.GetComponent <Text> ("ViewPort_Login/Group_CurServer/Txt_CurServer"); _goServerListPanel = _widget.GetComponent <Transform> ("ViewPort_ServerList").gameObject; yield return(InitServerList()); }
private void OnBtnClick_CreateRole(int job) { string tmpName = UnityEngine.Random.Range(10000, 99999).ToString(); LoginModule.GetInstance().NetWork_Request_CreateRole(tmpName, (uint)job); }
private void OnBtnClick_LoginWithOutNet() { NetWorkConst.IsOpenNetWork = false; GameManager.GetInstance().Init(); LoginModule.GetInstance().EnterGameScene(); }