少年修仙传客户端代码仓库
client_Wu Xijin
2018-10-11 b9898fcae3251b358ef42535d7144b7ae29a4a0c
Merge branch 'master' of http://192.168.0.87:10010/r/snxxz_scripts
3个文件已修改
117 ■■■■ 已修改文件
System/Strengthening/WashMasterActiveWin.cs 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
System/Vip/VipInvest/RotatePointer.cs 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
System/Vip/VipInvest/WheelOfFortuneWin.cs 113 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
System/Strengthening/WashMasterActiveWin.cs
@@ -216,7 +216,7 @@
            int[] curAttrValues = ConfigParse.GetMultipleStr<int>(curSpecConfig.attByLevelValue);
            raiseAttrCell.SetActive(false);
            tempCelllist.Add(GetRaiseGo(Language.Get("MainInterfacePanel_HeadPortraitTip_ZL"),preFightNum.ToString(),(curFightNum-preFightNum).ToString()));
            tempCelllist.Add(GetRaiseGo(Language.Get("L1056"),preFightNum.ToString(),(curFightNum-preFightNum).ToString()));
            for (int i = 0; i < preAttrIds.Length; i++)
            {
System/Vip/VipInvest/RotatePointer.cs
@@ -48,7 +48,7 @@
            if (!_isRotate)
            {
                if (Math.Abs((360 - Angle) - transform.eulerAngles.z) > 2)
                if (Math.Abs((360 - Angle) - transform.eulerAngles.z) > 2 && Angle- transform.eulerAngles.z!=0)
                {
                    transform.localRotation = Quaternion.Euler(0, 0, -Angle);
                    m_CheckDisplay.ShowSelected(wheelOfFortuneModel.Lattice);
System/Vip/VipInvest/WheelOfFortuneWin.cs
@@ -23,8 +23,9 @@
        [SerializeField] Text Money2_Text;
        [SerializeField] Text m_Text_remainingTimes;
        [SerializeField] Button m_PromotionBtn;
        [SerializeField] RotationTween m_RotationTween;
        [Header("滚动时间")]
        public  float RollingTime = 1f;
        public float RollingTime = 1f;
        VipModel m_Vipmodel;
        VipModel vipmodel { get { return m_Vipmodel ?? (m_Vipmodel = ModelCenter.Instance.GetModel<VipModel>()); } }
        WheelOfFortuneModel wheelOfFortuneModel { get { return ModelCenter.Instance.GetModel<WheelOfFortuneModel>(); } }
@@ -43,19 +44,25 @@
        }
        protected override void OnPreOpen()
        {
        {
            FairyJade = (int)UIHelper.GetMoneyCnt(2);
            Money1_Text.text = FairyJade.ToString();
            Money2_Text.text = UIHelper.GetMoneyCnt(1).ToString();
            m_RotatePointer.Init();
            IsLottery();//判断是否拥有次数
        }
            m_LotteryBtn.interactable = true;
            RemainingTimes();//剩余次数
        }
        protected override void OnActived()
        {
            Money1_Text.transform.localRotation = Quaternion.Euler(0, 0, 0);
            m_RotationTween.enabled = false;
        }
        protected override void OnAfterOpen()
        {
            wheelOfFortuneModel.WheelOfFortuneUpdate += WheelOfFortuneUpdate;
            RotatePointer.IsButtonShow += IsButtonShow;
            CheckDisplay.EndOfFlashing += EndOfFlashing;
            CheckDisplay.EndOfFlashing += EndOfFlashing;
            PlayerDatas.Instance.PlayerDataRefreshInfoEvent += Updatefighting;//数据的刷新(h0418)
            if (wheelOfFortuneModel.redPointStre1.state == RedPointState.Simple)
            {
                int GetDayOfYear = DateTime.Now.DayOfYear;
@@ -70,6 +77,15 @@
            wheelOfFortuneModel.WheelOfFortuneUpdate -= WheelOfFortuneUpdate;
            RotatePointer.IsButtonShow -= IsButtonShow;
            CheckDisplay.EndOfFlashing -= EndOfFlashing;
            PlayerDatas.Instance.PlayerDataRefreshInfoEvent -= Updatefighting;//数据的刷新(h0418)
        }
        private void Updatefighting(PlayerDataRefresh obj)
        {
            if (obj == PlayerDataRefresh.VIPLv)
            {
                RemainingTimes();//剩余次数
            }
        }
        private void EndOfFlashing()
@@ -81,7 +97,7 @@
        {
            m_LotteryBtn.interactable = false;
            m_RotatePointer.SetTime(m_Toggle.isOn);
            IsLottery();
            RemainingTimes();//剩余次数
        }
        protected override void OnAfterClose()
@@ -90,8 +106,22 @@
        private void OnClickButton()
        {
            m_CheckDisplay.CloseAll();
            wheelOfFortuneModel.StartTheDraw();//开始抽奖
            int LotteryNumber = vipmodel.GetVipPrivilegeCnt(VipPrivilegeType.BindJadeWheel);
            if (LotteryNumber <= wheelOfFortuneModel.Number)
            {
                LackOfVIP(); //VIP 不足
                return;
            }
            else if (LotteryNumber > wheelOfFortuneModel.Number && (int)UIHelper.GetMoneyCnt(1) < wheelOfFortuneModel.NeedJade)
            {
                LackFairyJade();//仙玉不足
                return;
            }
            else if (LotteryNumber > wheelOfFortuneModel.Number && (int)UIHelper.GetMoneyCnt(1) >= wheelOfFortuneModel.NeedJade)
            {
                m_CheckDisplay.CloseAll();
                wheelOfFortuneModel.StartTheDraw();//开始抽奖
            }
        }
        private void OnClickToggle(bool _bool)
        {
@@ -105,38 +135,67 @@
            }
        }
        private void OnClickPromotionBtn()
        {
        {
            WindowJumpMgr.Instance.WindowJumpTo(JumpUIType.VipRechargeFunc4);
        }
        private void IsButtonShow(bool _bool)//是否可点击旋转
        {
            m_LotteryBtn.interactable = _bool;
        }
        private void IsLottery()
        private Sequence mScoreSequence;
        private void TiedJadeChange()//绑玉变化
        {
            m_RotationTween.enabled = true;
            mScoreSequence = DOTween.Sequence();
            mScoreSequence.SetAutoKill(false);
            mScoreSequence.Append(DOTween.To(delegate (float value)
            {
                var temp = Math.Floor(value);
                Money1_Text.text = temp + "";
            }, FairyJade, (int)UIHelper.GetMoneyCnt(2), RollingTime));
            mScoreSequence.AppendCallback(() =>
            {
                Money1_Text.transform.localRotation = Quaternion.Euler(0, 0, 0);
                m_RotationTween.enabled = false;
            });
            FairyJade = (int)UIHelper.GetMoneyCnt(2);
        }
        private void LackOfVIP()//VIP 不足
        {
            string str = "次数不足,请提升VIP";
            ConfirmCancel.ShowPopConfirm(Language.Get("Mail101"), str, (bool isOk) =>
             {
                 if (isOk)
                 {
                     WindowJumpMgr.Instance.WindowJumpTo(JumpUIType.VipRechargeFunc4);
                 }
             });
        }
        private void LackFairyJade()//仙玉不足
        {
            if (VersionConfig.Get().isBanShu)
            {
                SysNotifyMgr.Instance.ShowTip("GoldErr");
                return;
            }
            WindowCenter.Instance.Open<RechargeTipWin>();
        }
        private void RemainingTimes()//剩余次数
        {
            int LotteryNumber = vipmodel.GetVipPrivilegeCnt(VipPrivilegeType.BindJadeWheel);
            if (LotteryNumber > wheelOfFortuneModel.Number)
            {
                remainingTimes = LotteryNumber - wheelOfFortuneModel.Number;
                m_LotteryBtn.interactable = true;
                m_Text_remainingTimes.text = "今日可转动次数:" + (LotteryNumber - wheelOfFortuneModel.Number);
            }
            else
            {
                m_LotteryBtn.interactable = false;
                m_Text_remainingTimes.text = "今日可转动次数:0";
            }
        }
        private Sequence mScoreSequence;
        private void TiedJadeChange()//绑玉变化
        {
            mScoreSequence = DOTween.Sequence();
            mScoreSequence.SetAutoKill(false);
            mScoreSequence.Append(DOTween.To(delegate(float value)
            {
                var temp = Math.Floor(value);
                Money1_Text.text = temp + "";
            }, FairyJade,(int)UIHelper.GetMoneyCnt(2), RollingTime));
            FairyJade = (int)UIHelper.GetMoneyCnt(2);
        }
        #endregion