Beispiel #1
0
    /// <summary>
    /// 充值
    /// </summary>
    /// <param name="rechargeID"></param>
    public void DoRecharge(uint rechargeID)
    {
        if (!DataManager.Manager <LoginDataManager>().SDKLoginEnable)
        {
            TipsManager.Instance.ShowTips("当前平台充值不可用");
            return;
        }
        if (!m_bRechargeOpen)
        {
            TipsManager.Instance.ShowTips("充值暂未开放");
            return;
        }
        UIPanelManager    pmgr     = DataManager.Manager <UIPanelManager>();
        WaitPanelShowData waitData = new WaitPanelShowData();

        waitData.type       = WaitPanelType.Waitting;
        waitData.cdTime     = 20;
        waitData.des        = "充值中...";
        waitData.useBoxMask = false;
        waitData.showTimer  = false;
        if (!pmgr.IsShowPanel(PanelID.CommonWaitingPanel))
        {
            pmgr.ShowPanel(PanelID.CommonWaitingPanel, data: waitData);
        }
        RequestRechargeOrder(rechargeID);
    }
Beispiel #2
0
    void OnTotalPriceClick(GameObject go)
    {
        UIPanelManager mgr = DataManager.Manager <UIPanelManager>();

        if (mgr.IsShowPanel(PanelID.HandInputPanel))
        {
            mgr.HidePanel(PanelID.HandInputPanel);
        }
        else
        {
            mgr.ShowPanel(PanelID.HandInputPanel, data: new HandInputPanel.HandInputInitData()
            {
                maxInputNum             = 10000,
                onInputValue            = OnTotalPriceCofirm,
                showLocalOffsetPosition = new Vector3(322, -110, 0),
            });
        }
    }
Beispiel #3
0
    void onClick_InputBtnArea_Btn(GameObject caster)
    {
        UIPanelManager mgr = DataManager.Manager <UIPanelManager>();

        if (mgr.IsShowPanel(PanelID.HandInputPanel))
        {
            mgr.HidePanel(PanelID.HandInputPanel);
        }
        else
        {
            mgr.ShowPanel(PanelID.HandInputPanel, data: new HandInputPanel.HandInputInitData()
            {
                maxInputNum             = (uint)MaxInputNum,
                onInputValue            = onClick_HandInputBtnConfirm_Btn,
                showLocalOffsetPosition = new Vector3(425, 0, 0),
            });
        }
    }
Beispiel #4
0
    void OnNumClick(GameObject caster)
    {
        UIPanelManager mgr = DataManager.Manager <UIPanelManager>();

        if (mgr.IsShowPanel(PanelID.HandInputPanel))
        {
            mgr.HidePanel(PanelID.HandInputPanel);
        }
        else
        {
            mgr.ShowPanel(PanelID.HandInputPanel, data: new HandInputPanel.HandInputInitData()
            {
                maxInputNum             = (uint)maxNum,
                onInputValue            = OnNumConfirm,
                showLocalOffsetPosition = new Vector3(322, -40, 0),
            });
        }
    }
Beispiel #5
0
    void OnNumInput(GameObject go)
    {
        UIPanelManager mgr = DataManager.Manager <UIPanelManager>();

        if (mgr.IsShowPanel(PanelID.HandInputPanel))
        {
            mgr.HidePanel(PanelID.HandInputPanel);
        }
        else
        {
            mgr.ShowPanel(PanelID.HandInputPanel, data: new HandInputPanel.HandInputInitData()
            {
                maxInputNum             = SendRedEnvelopeMaxNum,
                onInputValue            = OnNumConfirm,
                showLocalOffsetPosition = new Vector3(322, -180, 0),
            });
        }
    }
Beispiel #6
0
    void onClick_HandInputBtn_Btn(GameObject caster)
    {
        UIPanelManager mgr = DataManager.Manager <UIPanelManager>();

        if (mgr.IsShowPanel(PanelID.HandInputPanel))
        {
            mgr.HidePanel(PanelID.HandInputPanel);
        }
        else
        {
            mgr.ShowPanel(PanelID.HandInputPanel, data: new HandInputPanel.HandInputInitData()
            {
                maxInputNum             = MAX_RECHANGE_NUM,
                onInputValue            = OnHandInput,
                onClose                 = OnCloseInput,
                showLocalOffsetPosition = new Vector3(308, 113, 0),
            });
        }
    }
Beispiel #7
0
    void onClick_WareHouseStoreCopperHandInput_Btn(GameObject caster)
    {
        UIPanelManager mgr = DataManager.Manager <UIPanelManager>();

        if (mgr.IsShowPanel(PanelID.HandInputPanel))
        {
            mgr.HidePanel(PanelID.HandInputPanel);
        }
        else
        {
            mgr.ShowPanel(PanelID.HandInputPanel, data: new HandInputPanel.HandInputInitData()
            {
                onInputValue            = OnWareHouseStoreTakeOutCopperNumInput,
                showLocalOffsetPosition = new Vector3(299, -63f, 0),
                maxInputNum             = Math.Max((uint)UserData.Coupon, (uint)DataManager.Manager <KnapsackManager>().WareHouseStoreCopperNum),
                onGetInputMaxDlg        = GetRefreshStoreCopperMaxNum,
            });
        }
    }
Beispiel #8
0
    void onClick_TakeOutNumInput_Btn(GameObject caster)
    {
        UIPanelManager mgr = DataManager.Manager <UIPanelManager>();

        if (mgr.IsShowPanel(PanelID.HandInputPanel))
        {
            mgr.HidePanel(PanelID.HandInputPanel);
        }
        else
        {
            mgr.ShowPanel(PanelID.HandInputPanel, data: new HandInputPanel.HandInputInitData()
            {
                maxInputNum             = (uint)itemCount,
                onInputValue            = OnHandInput,
                onClose                 = OnCloseInput,
                showLocalOffsetPosition = new Vector3(350, 0, 0),
            });
        }
    }
Beispiel #9
0
    void onClick_CarryShopPurchaseHandInput_Btn(GameObject caster)
    {
        UIPanelManager mgr = DataManager.Manager <UIPanelManager>();

        if (mgr.IsShowPanel(PanelID.HandInputPanel))
        {
            mgr.HidePanel(PanelID.HandInputPanel);
        }
        else
        {
            transform.GetChild(0).localPosition = new UnityEngine.Vector3(-178, 0, 0);
            mgr.ShowPanel(PanelID.HandInputPanel, data: new HandInputPanel.HandInputInitData()
            {
                maxInputNum  = (uint)data.MaxPurchaseNum,
                onInputValue = OnInputValue,
                onClose      = OnCloseInputPanel,

                showLocalOffsetPosition = new Vector3(354, 0, 0),
            });
        }
    }
Beispiel #10
0
    void onClick_InputBtnArea_Btn(GameObject caster)
    {
        if (false == this.canSetNum)
        {
            return;
        }

        UIPanelManager mgr = DataManager.Manager <UIPanelManager>();

        if (mgr.IsShowPanel(PanelID.HandInputPanel))
        {
            mgr.HidePanel(PanelID.HandInputPanel);
        }
        else
        {
            mgr.ShowPanel(PanelID.HandInputPanel, data: new HandInputPanel.HandInputInitData()
            {
                maxInputNum             = (uint)this.availableNum,
                onInputValue            = SetItemNum,
                showLocalOffsetPosition = new Vector3(425, 0, 0),
            });
        }
    }
Beispiel #11
0
    void onClick_HandInputBtn_Btn(GameObject caster)
    {
        if (!IsHavePurchaseTimes())
        {
            TipsManager.Instance.ShowTips("今日购买已达上限,请明日再来");
            return;
        }
        UIPanelManager mgr = DataManager.Manager <UIPanelManager>();

        if (mgr.IsShowPanel(PanelID.HandInputPanel))
        {
            mgr.HidePanel(PanelID.HandInputPanel);
        }
        else
        {
            mgr.ShowPanel(PanelID.HandInputPanel, data: new HandInputPanel.HandInputInitData()
            {
                maxInputNum             = (uint)CurrentMallData.MaxPurchaseNum,
                onInputValue            = OnHandInput,
                onClose                 = OnCloseInput,
                showLocalOffsetPosition = new Vector3(308, 113, 0),
            });
        }
    }
Beispiel #12
0
    public void OnCompeleteCopy(stCompleteCopyUserCmd_S cmd)
    {
        m_uCopyCountDown       = cmd.close_time;
        m_uCopyFinishCountDown = cmd.close_time;
        CopyDataBase cdb = GameTableManager.Instance.GetTableItem <CopyDataBase>(m_uEnterCopyID);

        if (cdb != null)
        {
            if (cdb.IsShowFinish)
            {
                UIPanelManager upMger = DataManager.Manager <UIPanelManager>();
                upMger.ShowPanel(PanelID.FBResult);
                TimerAxis.Instance().SetTimer(m_uCopyFinishTimerID, 1000, this, cmd.close_time);
                //延迟两秒显示副本奖励
                CoroutineMgr.Instance.DelayInvokeMethod(2f, () =>
                {
                    if (upMger.IsShowPanel(PanelID.FBResult))
                    {
                        upMger.HidePanel(PanelID.FBResult);
                    }
                    if (cdb.havePassReward != 0 && !string.IsNullOrEmpty(cdb.rewardList))
                    {
                        string[] rewardListStr           = cdb.rewardList.Split(new char[] { ';' });
                        List <CommonAwardData> cmADDAtas = null;
                        CommonAwardData tempcmAD         = null;
                        string[] tempRewardArray         = null;
                        uint tempItemID = 0;
                        uint tempNum    = 0;
                        if (null != rewardListStr && rewardListStr.Length > 0)
                        {
                            for (int i = 0, max = rewardListStr.Length; i < max; i++)
                            {
                                if (string.IsNullOrEmpty(rewardListStr[i]))
                                {
                                    continue;
                                }
                                tempRewardArray = rewardListStr[i].Split(new char[] { '_' });
                                if (null == tempRewardArray || tempRewardArray.Length != 2)
                                {
                                    continue;
                                }
                                if (!string.IsNullOrEmpty(tempRewardArray[0]) && uint.TryParse(tempRewardArray[0].Trim(), out tempItemID) &&
                                    !string.IsNullOrEmpty(tempRewardArray[1]) && uint.TryParse(tempRewardArray[1].Trim(), out tempNum)
                                    )
                                {
                                    tempcmAD = new CommonAwardData(tempItemID, tempNum);
                                    if (null == cmADDAtas)
                                    {
                                        cmADDAtas = new List <CommonAwardData>();
                                    }
                                    CopyInfo info = GetCopyInfoById(m_uEnterCopyID);
                                    if (!info.IsFinished)
                                    {
                                        cmADDAtas.Add(tempcmAD);
                                    }
                                }
                            }
                            //超过收益次数  还是显示奖励界面但是没有奖励道具
                            if (null != cmADDAtas)
                            {
                                upMger.ShowPanel(PanelID.FBPassAwardPanel, data: cmADDAtas);
                            }
                        }
                    }
                });
            }
        }
    }