예제 #1
0
    // 初始化
    void Awake()
    {
        tfBoxChecking    = transform.Find("Container/BoxChecking");
        checkingTip      = tfBoxChecking.Find("Tip").GetComponent <UILabel>();
        checkingTip.text = "";// GameText.GetStr("versionCheck");

        _healthTips    = transform.Find("Background");
        tfBoxLoading   = transform.Find("Container/BoxLoading");
        loadingTip     = tfBoxLoading.Find("Tip").GetComponent <UILabel>();
        tfSlider       = tfBoxLoading.Find("slider");
        sliderProgress = tfSlider.GetComponent <UISlider>();

        tfOKButton        = tfBoxLoading.Find("OKButton");
        OKButtonText      = tfOKButton.Find("Text").GetComponent <UILabel>();
        OKButtonText.text = "确定";//GameText.GetStr("update");
        UIEventListener.Get(tfOKButton.gameObject).onClick = OnClickOKButton;
        versionShowLb = transform.Find <UILabel>("versionShowLb");
        _BeiJing      = transform.Find <UITexture>("BeiJing");

        versionShowLb.text = string.Format("v{0}.{1}", ClientDefine.LOCAL_PROGRAM_VERSION, VersionData.GetLocalVersion());

        loadingBox       = transform.Find <GameObject>("Loading/BoxLoading");
        loadingBoxSilder = loadingBox.transform.Find <UISlider>("slider");
        _loadingBoxTip   = loadingBox.transform.Find <UILabel>("Tip");

        serverTip = transform.Find("Container/ServerListTip").gameObject;
        if (GameDataMgr.LOGIN_DATA == null)
        {
            serverTip.SetActive(true);
        }

        _loginContainer = transform.Find <GameObject>("Loading/loginContainer");
        _btnTouris      = transform.Find <GameObject>("Loading/loginContainer/btnTouris");
        _btnPhone       = transform.Find <GameObject>("Loading/loginContainer/btnPhone");
        _selectBox      = transform.Find <GameObject>("Loading/loginContainer/gou");
        _gouObj         = transform.Find <GameObject>("Loading/loginContainer/selectBox");
        _btnAgree       = transform.Find <GameObject>("Loading/loginContainer/btnAgree");

        GameObject btnTour = transform.Find <GameObject>("Loading/loginContainer/btnTouris2");

        if (VersionData.IsReviewingVersion())
        {
            btnTour.gameObject.SetActive(true);
            _btnTouris.gameObject.SetActive(false);
        }
        else
        {
            btnTour.gameObject.SetActive(false);
            _btnTouris.gameObject.SetActive(true);
        }
        UIEventListener.Get(_selectBox).onClick = OnClickSelectBox;
        UIEventListener.Get(_btnAgree).onClick  = OnClickBtnAgreeWin;
        UIEventListener.Get(_btnPhone).onClick  = OnPhoneLoginHandler;
        UIEventListener.Get(_btnTouris).onClick = OnTourisLoginHandler;
        UIEventListener.Get(btnTour).onClick    = OnTourisLoginHandler;

//	    EventSystem.RegisterEvent(EventID.SHOW_LOGIN_BTN,ShowLoginBtn);
        var ctrl = UIManager.GetControler <LoginInputController>();

        ctrl.SetLoginShow(ShowLoginBtn);
    }
예제 #2
0
 private string hotScriptUrl()
 {
     return(sdk.SDKManager.LuaHotScriptURL + ClientDefine.LOCAL_PROGRAM_VERSION + "/" + VersionData.GetLocalVersion() + "/luaCode/");
 }