少年修仙传客户端代码仓库
Client_PangDeRong
2018-10-18 d50a8becc3afabc248f1f46ec544ec84a81d4c2d
2163 限时抢购界面倒计时没有按需求显示
2个文件已修改
34 ■■■■ 已修改文件
System/OpenServerActivity/FlashSaleTimeCell.cs 15 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
System/OpenServerActivity/OperationFlashRushToBuy.cs 19 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
System/OpenServerActivity/FlashSaleTimeCell.cs
@@ -65,12 +65,19 @@
            switch (buyState)
            {
                case -1:
                    this.gameObject.SetActive(true);
                    string timeStr = operation.ToDisplayBuyTime(date.month, dayIndex + date.day, operationTime.startHour, operationTime.startMinute);
                    remainText.text = Language.Get("FlashRushToBuy106", timeStr);
                    string timeStr = "";
                    if(seconds > 7200)
                    {
                        timeStr = operation.ToDisplayBuyTime(date.month, dayIndex + date.day, operationTime.startHour, operationTime.startMinute);
                        remainText.text = Language.Get("FlashRushToBuy106", timeStr);
                    }
                    else
                    {
                        timeStr = TimeUtility.SecondsToHMS(seconds);
                        remainText.text = Language.Get("FlashRushToBuy108", timeStr);
                    }
                    break;
                case 0:
                    this.gameObject.SetActive(true);
                    remainText.text = Language.Get("FlashRushToBuy105", TimeUtility.SecondsToHMS(seconds));
                    break;
                case 1:
System/OpenServerActivity/OperationFlashRushToBuy.cs
@@ -91,9 +91,22 @@
        {
            if(PlayerDatas.Instance.baseData.LV >= limitLv)
            {
                if(InAdvanceTime(TimeUtility.ServerNow) || InTime(TimeUtility.ServerNow))
                if(flashShops.Count > 0)
                {
                    return true;
                    int openSeconds = 0;
                    int endSeconds = 0;
                    var fristShop = flashShops[0];
                    var lastShop = flashShops[flashShops.Count - 1];
                    int OpenState = GetBuyTimeState(TimeUtility.ServerNow,fristShop.dayIndex,fristShop.timeIndex, out openSeconds);
                    int endState = GetBuyTimeState(TimeUtility.ServerNow,lastShop.dayIndex, lastShop.timeIndex,out endSeconds);
                    if(OpenState == -1 && openSeconds <= inAdvanceMinute*60)
                    {
                        return true;
                    }
                    else if(endState != 1 && OpenState != -1)
                    {
                        return true;
                    }
                }
            }
            return false;
@@ -132,7 +145,7 @@
                    var item = new FlashSaleItem();
                    var saleItem = shop.GiftbagInfo[k];
                    item.shopId = (int)saleItem.GiftID;
                    item.shopGuid = shop.DayIndex*1000 + shop.TimeIndex*100 + k;
                    item.shopGuid = shop.DayIndex*10000 + shop.TimeIndex*100 + k;
                    item.limitNum = saleItem.BuyCountLimit;
                    item.fullServerLimitNum = saleItem.ServerBuyCountLimit;
                    item.moneyType = saleItem.MoneyType;