Ejemplo n.º 1
0
 private void BtnCloseOnClick()
 {
     UIManager.Instance.Clear();
     //跳转大厅场景
     XUIUtils.LoadSceneX((int)SceneType.Hall);
     AudioManager.Instance.PlayerBgAudio("loadingbg");
 }
Ejemplo n.º 2
0
 public override void OnAwake()
 {
     DiceTcpOperation = new GameDiceTcpRoomOperation();
     base.OnAwake();
     btn_Kick = XUIUtils.GetCompmentT <Button>(transform, "btn_Kick");
     XUIUtils.ListenerBtn(btn_Kick, BtnKickOnClick);
 }
Ejemplo n.º 3
0
    public override void OnAwake()
    {
        //   ExcelUtils.Instance.init("Asset/Excel");
        MessageManager.GetInstance.InsertUIDict(this.GetType(), this);
        btn_Close   = XUIUtils.GetCompmentT <Button>(transform, "BackBtn");
        btn_Upgrade = XUIUtils.GetCompmentT <Button>(transform, "UpgradeBtn");
        btn_AddGold = XUIUtils.GetCompmentT <Button>(transform, "glodcountBg/PlusBtn");
        btn_Harvest = XUIUtils.GetCompmentT <Button>(transform, "HarvestBtn");


        slider = XUIUtils.GetCompmentT <Slider>(transform, "SlideImage");

        timer     = XUIUtils.GetCompmentT <Text>(transform, "SlideImage/time");
        level     = XUIUtils.GetCompmentT <Text>(transform, "SlideImage/Level");
        goldcount = XUIUtils.GetCompmentT <Text>(transform, "Treegather/goldcount");
        totalGold = XUIUtils.GetCompmentT <Text>(transform, "glodcountBg/Text");


        XUIUtils.ListenerBtn(btn_Close, BtnCloseOnClick);
        XUIUtils.ListenerBtn(btn_Upgrade, BtnUpgradeOnClick);
        XUIUtils.ListenerBtn(btn_AddGold, BtnAddGoldOnClick);
        XUIUtils.ListenerBtn(btn_Harvest, BtnHarvestOnClick);
        canvasGroup.blocksRaycasts = true;
        moneyTreeOperation         = new MoneyTreeOperation();
        MoneyTreeOpenDto moneyTreeOpenDto = moneyTreeOperation.open(PlayerCache.loginInfo.uid);

        if (moneyTreeOpenDto != null)
        {
            UpdateUI(moneyTreeOpenDto);
        }
    }
Ejemplo n.º 4
0
    public void StartWXLogin(WeiXinInfo info)
    {
        SetThirdLoginInfo("WX-" + info.openid, "123458", info.nickname, info.headimgurl, LoginType.WX);
        string sex = null;

        if (info.sex == "1")
        {
            sex = "男";
        }
        else
        {
            sex = "女";
        }
        string acc = SecurityUtils.AESEncrypt("WX-" + info.openid, kv[0], kv[1]);
        string pwd = SecurityUtils.AESEncrypt("123458", kv[0], kv[1]);
        //string[] msg = new string[] { "1", ((int)LoginType.WX).ToString(), acc, pwd, info.nickname, info.headimgurl, sex, Application.version };

        LoginOperation loginOperation = new LoginOperation();
        LoginDto       loginDto       = loginOperation.regist(info.openid, "123", "123", "123", "123", "123");

        if (loginDto != null)
        {
            //登录成功 跳转场景
            PlayerCache.loginInfo = loginDto;
            UIManager.Instance.Clear();
            XUIUtils.LoadSceneX((int)SceneType.Hall);
        }
        else
        {
            XUIMidMsg.QuickMsg("登录失败,请稍后再试!!!");
        }
    }
Ejemplo n.º 5
0
 public override void OnAwake()
 {
     MessageManager.GetInstance.InsertUIDict(this.GetType(), this);
     base.OnAwake();
     startChangeCard          = true;
     changedStartPos          = new Vector3(270, 60, 0);
     exchangeExpend           = new int[] { 1, 2, 3 };
     currentCardIndex         = -1;
     currentExchangeCardCount = 0;
     exchangeTimes            = 1;
     changedCardList          = new List <Transform>();
     ChangeCard    = XUIUtils.GetCompmentT <Transform>(transform, "ChangeCard");
     btn_selfCards = new List <Button>();
     for (int i = 3; i < ChangeCard.childCount; i++)
     {
         btn_selfCards.Add(ChangeCard.GetChild(i).GetComponent <Button>());
     }
     btn_ChangeCard      = XUIUtils.GetCompmentT <Button>(transform, "btn_ChangeCard");
     btn_CloseChangeCard = XUIUtils.GetCompmentT <Button>(transform, "ChangeCard/btn_Close");
     XUIUtils.ListenerBtn(btn_ChangeCard, BtnChangeCardOnClick);
     XUIUtils.ListenerBtn(btn_CloseChangeCard, BtnCloseChangeCardOnClick);
     changedCard = XUIUtils.GetCompmentT <Transform>(transform, "Players/self/Player/ChangedCard");
     CardTrans   = XUIUtils.GetCompmentT <Transform>(transform, "Players/Cards");
     selfChangeCardParentTrans = transform.Find("Players/self/Player/ChangedCard");
     exchangeCardTxt           = XUIUtils.GetCompmentT <Text>(transform, "btn_ChangeCard/countImg/countTxt");
     for (int i = 0; i < btn_selfCards.Count; i++)
     {
         int j = i;
         btn_selfCards[i].onClick.AddListener(delegate() { this.BtnChangeCardOnClick(j); });
     }
 }
Ejemplo n.º 6
0
    public override void OnAwake()
    {
        isClickLoginBtn = false;
        key             = "apiunmdw154sof65";
        iv = "asdf9a8fa2fs5sdf";
        GenerateKeyIv(out kv);
        MessageManager.GetInstance.InsertUIDict(this.GetType(), this);
        AddLoginCommand();
        btn_CloseWXLogin = XUIUtils.GetCompmentT <Button>(transform, "ThirdLogin/btn_Close");
        login            = XUIUtils.GetCompmentT <Transform>(transform, "login");
        versionTxt       = XUIUtils.GetCompmentT <Text>(transform, "versionsContentText");
        btn_WXLogin      = XUIUtils.GetCompmentT <Button>(transform, "login/WeChatLoginBtn");

        btn_Login  = XUIUtils.GetCompmentT <Button>(transform, "ThirdLogin/btn_Login");
        thirdLogin = XUIUtils.GetCompmentT <Transform>(transform, "ThirdLogin");

        XUIUtils.ListenerBtn(btn_CloseWXLogin, BtnCloseWXOnClick);
        XUIUtils.ListenerBtn(btn_WXLogin, BtnWXLoginOnClick);
        XUIUtils.ListenerBtn(btn_Login, BtnLoginOnClick);

        //btn_CloseWXLogin.onClick.AddListener(BtnCloseWXOnClick);

        //btn_WXLogin.onClick.AddListener(BtnWXLoginOnClick);
        //btn_Login.onClick.AddListener(BtnLoginOnClick);
        GameObject canvas = GameObject.Find("Canvas");

        loginByWX = canvas.AddComponent <UILoginByWX>();
        if (versionTxt != null)
        {
            versionTxt.text = Application.version;
        }
    }
Ejemplo n.º 7
0
    // private int[] shopid;
    public override void OnAwake()
    {
        MessageManager.GetInstance.InsertUIDict(this.GetType(), this);

        dimandPanel   = XUIUtils.GetCompmentT <Transform>(transform, "TogglePanel/ZuanShiPanel");
        goldPanel     = XUIUtils.GetCompmentT <Transform>(transform, "TogglePanel/GoldPanel");
        daojuPanel    = XUIUtils.GetCompmentT <Transform>(transform, "TogglePanel/DaojuPanel");
        lianghaoPanel = XUIUtils.GetCompmentT <Transform>(transform, "TogglePanel/LianghaoPanel");
        carPanel      = XUIUtils.GetCompmentT <Transform>(transform, "TogglePanel/CarPanel");

        dimandPanel.gameObject.AddComponent <ZuanShiPanel>();
        goldPanel.gameObject.AddComponent <GoldPanel>();
        daojuPanel.gameObject.AddComponent <DaojuPanel>();
        carPanel.gameObject.AddComponent <CarPanel>();

        ShoptoggleDIC = new Dictionary <ShopType, Toggle>();
        //获取到五个Toggle
        dimandtoggle   = transform.GetChild(5).GetChild(5).GetComponent <Toggle>();
        goldtoggle     = transform.GetChild(5).GetChild(6).GetComponent <Toggle>();
        exchangetoggle = transform.GetChild(5).GetChild(7).GetComponent <Toggle>();
        lianghaotoggle = transform.GetChild(5).GetChild(8).GetComponent <Toggle>();
        cartoggle      = transform.GetChild(5).GetChild(9).GetComponent <Toggle>();
        //存进字典
        ShoptoggleDIC.Add(ShopType.Dimand, dimandtoggle);
        ShoptoggleDIC.Add(ShopType.Golds, goldtoggle);
        ShoptoggleDIC.Add(ShopType.Exchange, exchangetoggle);
        ShoptoggleDIC.Add(ShopType.BeautifulNumber, lianghaotoggle);
        ShoptoggleDIC.Add(ShopType.Cars, cartoggle);
    }
Ejemplo n.º 8
0
    private void BtnWXLoginOnClick()
    {
        // AudioManager.Instance.PlaySound("button");
        if (Application.platform == RuntimePlatform.WindowsEditor)
        {
            string         acc            = SecurityUtils.AESEncrypt("WX-o2xMF1vxkphDaUP88lkypIYwN14E", kv[0], kv[1]);
            string         pwd            = SecurityUtils.AESEncrypt("123458", kv[0], kv[1]);
            LoginOperation loginOperation = new LoginOperation();
            LoginDto       loginDto       = loginOperation.regist(UnityEngine.Random.Range(1, 10000).ToString(), UnityEngine.Random.Range(1, 100000).ToString(), "123", "Default_" + UnityEngine.Random.Range(0, 7), "男", "123");

            if (loginDto != null)
            {
                //SaveLoginInfo();
                //登录成功 跳转场景
                PlayerCache.loginInfo = loginDto;
                UIManager.Instance.Clear();

                TcpSocketImpl.getInstance().init();
                ClientTcpIoMessage ioMessage = new ClientTcpIoMessage();
                ioMessage.methodName    = "";
                ioMessage.interfaceName = "";
                List <object> list = new List <object>(2);
                list.Add(loginDto.uid);
                list.Add(loginDto.secretKey);

                ioMessage.args = JsonMapper.ToJson(list);
                TcpSocketImpl.getInstance().async(ioMessage, 1, -100);
                XUIUtils.LoadSceneX((int)SceneType.Hall);
            }
        }
        else
        {
            loginByWX.LoginByWX();
        }
    }
Ejemplo n.º 9
0
    public override void OnAwake()
    {
        if (!isAwake)
        {
            //从表里读取礼物信息

            MessageManager.GetInstance.InsertUIDict(this.GetType(), this);
            giftTable = ShopInit.Instance.GetShopCommodity(100);
            Transform trans = transform.Find("Items/Grid");
            giftNumberList = new Dictionary <int, Text>();
            btn_Pawn       = XUIUtils.GetCompmentT <Button>(transform, "btn_Pawn");
            XUIUtils.ListenerBtn(btn_Pawn, BtnPawnOnClick);
            for (int i = 0; i < giftTable.Count; i++)
            {
                GameObject go  = Resources.Load <GameObject>("Prefabs/Head/gift");
                GameObject obj = Instantiate(go);
                obj.name = "gift_" + i.ToString();
                string path   = "Sprite/Shop/gift/new_gift_" + i.ToString();
                Sprite sprite = Resources.Load <Sprite>(path);
                obj.transform.GetChild(1).GetComponent <Image>().sprite = sprite;
                obj.transform.SetParent(trans);
                obj.transform.localScale = Vector3.one;
                obj.transform.GetChild(2).GetComponent <Text>().text = giftTable[i].name;
                giftNumberList.Add(giftTable[i].id, obj.transform.GetChild(3).GetComponent <Text>());
            }
            canvas  = GameObject.Find("Canvas").transform;
            isAwake = true;
        }
    }
Ejemplo n.º 10
0
    public override void OnAwake()
    {
        if (!isAwake)
        {
            MessageManager.GetInstance.InsertUIDict(this.GetType(), this);
            currentGoldTxt = XUIUtils.GetCompmentT <Text>(transform, "currentGold/Text");
            walletGoldTxt  = XUIUtils.GetCompmentT <Text>(transform, "bankGold/Text");
            totalGoldTxt   = XUIUtils.GetCompmentT <Text>(transform, "totalGold/Text");

            DepositInput = XUIUtils.GetCompmentT <InputField>(transform, "Deposit/InputField");
            ExtractInput = XUIUtils.GetCompmentT <InputField>(transform, "Extract/InputField");

            btn_Deposit = XUIUtils.GetCompmentT <Button>(transform, "Deposit/btn_Deposit");
            btn_Extract = XUIUtils.GetCompmentT <Button>(transform, "Extract/btn_Extract");

            btn_ExtractSub = XUIUtils.GetCompmentT <Button>(transform, "Extract/btn_Sub");
            btn_ExtractAdd = XUIUtils.GetCompmentT <Button>(transform, "Extract/btn_Add");
            btn_DepositSub = XUIUtils.GetCompmentT <Button>(transform, "Deposit/btn_Sub");
            btn_DepositAdd = XUIUtils.GetCompmentT <Button>(transform, "Deposit/btn_Add");
            XUIUtils.ListenerBtn(btn_Deposit, BtnDepositOnClick);
            XUIUtils.ListenerBtn(btn_Extract, BtnExtractOnClick);
            XUIUtils.ListenerBtn(btn_ExtractSub, BtnExtractSubOnClick);
            XUIUtils.ListenerBtn(btn_ExtractAdd, BtnExtractAddOnClick);
            XUIUtils.ListenerBtn(btn_DepositSub, BtnDepositSubOnClick);
            XUIUtils.ListenerBtn(btn_DepositAdd, BtnDepositAddOnClick);

            DepositInput.onValueChanged.AddListener(DepositInputValueChange);
            ExtractInput.onValueChanged.AddListener(ExtractInputValueChange);
            isAwake = true;
        }
    }
Ejemplo n.º 11
0
 // Use this for initialization
 void Awake()
 {
     btn_Confirm = XUIUtils.GetCompmentT <Button>(transform, "btn_Confirm");
     btn_Cancel  = XUIUtils.GetCompmentT <Button>(transform, "btn_Cancel");
     XUIUtils.ListenerBtn(btn_Confirm, BtnConfirmOnClick);
     XUIUtils.ListenerBtn(btn_Cancel, BtnCancelOnClick);
 }
Ejemplo n.º 12
0
    public override void OnAwake()
    {
        MessageManager.GetInstance.InsertUIDict(this.GetType(), this);
        //从表里读取礼物信息
        giftTable = ShopInit.Instance.GetShopCommodity(100);
        btn_Close = XUIUtils.GetCompmentT <Button>(transform, "btn_Close");
        XUIUtils.ListenerBtn(btn_Close, BtnCloseOnClick);
        Transform trans = transform.Find("Items/Grid");

        giftNumberList = new Dictionary <int, Text>();

        for (int i = 0; i < giftTable.Count; i++)
        {
            int        j   = i;
            GameObject go  = Resources.Load <GameObject>("Prefabs/Friend/sendGiftItem");
            GameObject obj = Instantiate(go);
            obj.name = "gift_" + i.ToString();
            string path   = "Sprite/Shop/gift/new_gift_" + i.ToString();
            Sprite sprite = Resources.Load <Sprite>(path);
            obj.transform.GetChild(1).GetComponent <Image>().sprite = sprite;
            obj.transform.SetParent(trans);
            obj.transform.localScale = Vector3.one;
            obj.transform.GetChild(2).GetComponent <Text>().text = giftTable[i].selling.ToString();
            //添加点击事件
            obj.transform.GetChild(1).gameObject.AddComponent <Button>().onClick.AddListener(delegate() { this.BtnSendGiftOnClick(giftTable[j].id); });

            giftNumberList.Add(giftTable[i].id, obj.transform.GetChild(2).GetComponent <Text>());
        }
    }
Ejemplo n.º 13
0
    public override void OnStart()
    {
        btn_Close = XUIUtils.GetCompmentT <Button>(transform, "btn_Close");

        //添加按钮点击事件

        XUIUtils.ListenerBtn(btn_Close, BtnCloseOnClick);
    }
Ejemplo n.º 14
0
    public override void OnAwake()
    {
        MessageManager.GetInstance.InsertUIDict(this.GetType(), this);
        btn_Confirm = XUIUtils.GetCompmentT <Button>(transform, "btn_Confirm");
        tipsContent = XUIUtils.GetCompmentT <Text>(transform, "content");

        XUIUtils.ListenerBtn(btn_Confirm, BtnConfirmOnClick);
    }
Ejemplo n.º 15
0
 public override void OnAwake()
 {
     MessageManager.GetInstance.InsertUIDict(this.GetType(), this);
     btn_No     = XUIUtils.GetCompmentT <Button>(transform, "btn_No");
     btn_GoShop = XUIUtils.GetCompmentT <Button>(transform, "btn_Yes");
     XUIUtils.ListenerBtn(btn_No, BtnCloseOnClick);
     XUIUtils.ListenerBtn(btn_GoShop, BtnGoShopOnClick);
 }
Ejemplo n.º 16
0
    public override void OnStart()
    {
        btn_Close = XUIUtils.GetCompmentT <Button>(transform, "btn_Close");
        btn_Get   = XUIUtils.GetCompmentT <Button>(transform, "btn_Pay");

        XUIUtils.ListenerBtn(btn_Close, BtnCloseOnClick);
        XUIUtils.ListenerBtn(btn_Get, BtnGetOnClick);
    }
Ejemplo n.º 17
0
 private void Awake()
 {
     btn_confirm = XUIUtils.GetCompmentT <Button>(transform, "btn_Ok");
     XUIUtils.ListenerBtn(btn_confirm, BtnConfirmOnClick);
     transform.localScale = Vector3.zero;
     transform.DOScale(Vector3.one, 0.2f);
     transform.SetAsLastSibling();
 }
Ejemplo n.º 18
0
 public override void OnAwake()
 {
     base.OnAwake();
     MessageManager.GetInstance.InsertUIDict(this.GetType(), this);
     sysTrans   = XUIUtils.GetCompmentT <Transform>(transform, "ToggleGroup/systemTaskPanel");
     everyTrans = XUIUtils.GetCompmentT <Transform>(transform, "ToggleGroup/everyTaskPanel");
     sysTrans.gameObject.AddComponent <UISysTaskPanel>();
     sysTrans.gameObject.AddComponent <UIEveryTaskPanel>();
 }
Ejemplo n.º 19
0
 // Use this for initialization
 public override void Awake()
 {
     base.Awake();
     rawImage    = XUIUtils.GetCompmentT <RawImage>(transform, "QRcode");
     OpenWxSaner = XUIUtils.GetCompmentT <Button>(transform, "SaveQRcode");
     XUIUtils.ListenerBtn(OpenWxSaner, GotoWxScner);
     btn_Close = XUIUtils.GetCompmentT <Button>(transform, "btn_Close");
     XUIUtils.ListenerBtn(btn_Close, BtnCloseOnClick);
 }
Ejemplo n.º 20
0
 public override void OnStart()
 {
     btn_Close  = XUIUtils.GetCompmentT <Button>(transform, "btn_Close");
     btn_Search = XUIUtils.GetCompmentT <Button>(transform, "btn_Search");
     inputUID   = XUIUtils.GetCompmentT <InputField>(transform, "InputField");
     //添加按钮点击事件
     XUIUtils.ListenerBtn(btn_Close, BtnCloseOnClick);
     XUIUtils.ListenerBtn(btn_Search, BtnSearchOnClick);
 }
Ejemplo n.º 21
0
 public override void OnAwake()
 {
     base.OnAwake();
     MessageManager.GetInstance.InsertUIDict(this.GetType(), this);
     startEarnTrans  = XUIUtils.GetCompmentT <Transform>(transform, "StartEarnGoldPanel");
     earnRecordTrans = XUIUtils.GetCompmentT <Transform>(transform, "EarnRecordPanel");
     startEarnTrans.gameObject.AddComponent <UIStartEarnGoldPanel>();
     earnRecordTrans.gameObject.AddComponent <UIEarnRecordPanel>();
 }
Ejemplo n.º 22
0
    // Use this for initialization

    void Awake()
    {
        MessageManager.GetInstance.InsertUIDict(this.GetType(), this);
        //落牌位置数组初始化
        FallCardPosList = new RectTransform[5];
        //牌背面链表初始化
        cardBackList = new List <GameObject>(15);
        //牌型链表初始化
        cardTypeList = new Dictionary <int, Sprite>(7);
        //牌型显示链表初始化
        cardtypeShowlist = new List <Image>(4);
        cardTypeShowList = new Dictionary <int, Image>(4);
        cardDict         = new Dictionary <int, Sprite>();
        RedpagList       = new List <GameObject>();
        RedpagselectList = new List <Button>();
        //输赢图片链表初始化
        resultList = new Sprite[2];
        //输赢图片位置链表初始化
        ResultTrList = new List <Image>(4);
        resultTrList = new Dictionary <int, Image>(4);
        //获取发牌位置
        DealCardPos = XUIUtils.GetCompmentT <RectTransform>(transform, "DealCardPos");
        //获取加载牌的父物体
        parentT = XUIUtils.GetCompmentT <RectTransform>(transform, "FallCardPos");
        //获取牌背面预设物
        cardBack = Resources.Load("Prefabs/Game/WanRenChang/CardBack", typeof(GameObject)) as GameObject;

        //牌背面图片
        cardBackImg = cardBack.GetComponent <Image>().sprite;
        //遍历牌型显示链表给元素添加值
        for (int i = 1; i <= 4; i++)
        {
            Image image = XUIUtils.GetCompmentT <Image>(transform, "CardTypePos/CardType" + i);
            cardTypeShowList.Add(i, image);
            cardtypeShowlist.Add(image);
        }
        //遍历牌型链表给元素添加值
        for (int i = 1; i < 8; i++)
        {
            Sprite sprite = GameTools.Instance.GetSpriteAtlas("Sprite/WanRenChang/CardType/CardType", "cardtype" + i);
            cardTypeList.Add(i, sprite);
        }

        //遍历输赢图片位置链表给元素添加值
        for (int i = 0; i < 4; i++)
        {
            Image image = XUIUtils.GetCompmentT <Image>(transform, "BetArea/betarea" + i + "/Result" + i);
            ResultTrList.Add(image);
            resultTrList.Add(i, image);
        }
        //遍历输赢图片链表给元素添加值
        for (int i = 0; i < 2; i++)
        {
            Sprite sprite = Resources.Load <Sprite>("Sprite/WanRenChang/result" + i);
            resultList[i] = sprite;
        }
    }
Ejemplo n.º 23
0
 public override void OnAwake()
 {
     if (!isAwake)
     {
         MessageManager.GetInstance.InsertUIDict(this.GetType(), this);
         ContentParent = XUIUtils.GetCompmentT <Transform>(transform, "ScrollRect/viewer/content");
         isAwake       = true;
     }
 }
Ejemplo n.º 24
0
 // Use this for initialization
 void Start()
 {
     btn_Failure = XUIUtils.GetCompmentT <Button>(transform, "btn_Failure");
     btn_Success = XUIUtils.GetCompmentT <Button>(transform, "btn_Success");
     btn_Close   = XUIUtils.GetCompmentT <Button>(transform, "btn_Close");
     XUIUtils.ListenerBtn(btn_Failure, BtnFailureOnClick);
     XUIUtils.ListenerBtn(btn_Success, BtnSuccessOnClcik);
     XUIUtils.ListenerBtn(btn_Close, BtnCloseOnClick);
 }
Ejemplo n.º 25
0
 /// <summary>
 /// 切换账号 调到登录界面
 /// </summary>
 private void BtnSwitchaccounOnClick()
 {
     //string[] msg = new string[] { "10003" };
     //NetGameRoom.Instance.write(msg);
     //PlayerCache.Dealloc();
     PlayerCache.loginOut.loginOut(PlayerCache.loginInfo.uid, PlayerCache.loginInfo.secretKey);
     UIManager.Instance.Clear();
     XUIUtils.LoadSceneX(1);
 }
Ejemplo n.º 26
0
    public void Awake()
    {
        btn_Refuse  = XUIUtils.GetCompmentT <Button>(transform, "btn_Refuse");
        btn_Confirm = XUIUtils.GetCompmentT <Button>(transform, "btn_Confirm");
        content     = XUIUtils.GetCompmentT <Text>(transform, "content");

        XUIUtils.ListenerBtn(btn_Refuse, BtnRefuseOnClick);
        XUIUtils.ListenerBtn(btn_Confirm, BtnConfirmOnClick);
    }
Ejemplo n.º 27
0
    //public Transform enemyTrans;
    public override void OnAwake()
    {
        base.OnAwake();
        MessageManager.GetInstance.InsertUIDict(this.GetType(), this);
        friendTrans = XUIUtils.GetCompmentT <Transform>(transform, "ToggleGroup/MyFriendPanel");
        friendTrans.gameObject.AddComponent <UIMyFriendPanel>();

        //enemyTrans = XUIUtils.GetCompmentT<Transform>(transform, "ToggleGroup/MyEnemyPanel");
        //enemyTrans.gameObject.AddComponent<UIMyEnemyPanel>();
    }
Ejemplo n.º 28
0
    public override void OnAwake()
    {
        base.OnAwake();

        MessageManager.GetInstance.InsertUIDict(this.GetType(), this);
        btn_refresh = XUIUtils.GetCompmentT <Button>(transform, "btn_refresh");
        XUIUtils.ListenerBtn(btn_refresh, BtnRefreshOnClick);
        canvas   = GameObject.Find("Canvas").transform;
        posTrans = transform.Find("Items/ItemList").transform;
    }
Ejemplo n.º 29
0
    // Use this for initialization
    private void Awake()
    {
        btn_Close  = XUIUtils.GetCompmentT <Button>(transform, "btn_Close");
        btn_AliPay = XUIUtils.GetCompmentT <Button>(transform, "btn_AliPay");
        btn_WxPay  = XUIUtils.GetCompmentT <Button>(transform, "btn_WxPay");

        XUIUtils.ListenerBtn(btn_Close, BtnCloseOnClick);
        XUIUtils.ListenerBtn(btn_AliPay, BtnAliPayOnClick);
        XUIUtils.ListenerBtn(btn_WxPay, BtnWxPayOnClick);
    }
Ejemplo n.º 30
0
 public override void OnAwake()
 {
     base.OnAwake();
     MessageManager.GetInstance.InsertUIDict(this.GetType(), this);
     canvas          = GameObject.Find("Canvas").transform;
     goldRankTrans   = XUIUtils.GetCompmentT <Transform>(transform, "WealthRankPanel");
     renPinRankTrans = XUIUtils.GetCompmentT <Transform>(transform, "CharacterRankPanel");
     goldRankTrans.gameObject.AddComponent <UIGoldRankPanel>();
     renPinRankTrans.gameObject.AddComponent <UIRenPinRankPanel>();
 }