From 92e6e365b665ec939f75c8ed4083f2affeed36be Mon Sep 17 00:00:00 2001
From: client_Lhy <995049470@qq.com>
Date: 星期一, 24 六月 2019 10:13:03 +0800
Subject: [PATCH] 4230 【BUG】【2.0】显示可购买20个,实际只能买5个

---
 System/Store/BuyItemController.cs |    8 ++++----
 1 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/System/Store/BuyItemController.cs b/System/Store/BuyItemController.cs
index fe55468..92d9042 100644
--- a/System/Store/BuyItemController.cs
+++ b/System/Store/BuyItemController.cs
@@ -109,7 +109,7 @@
 
     public void SetBuyCount(int goodId, int count)
     {
-        var countLimit = GetBuyCountLimit(goodId, count);
+        var countLimit = GetBuyCountLimit(goodId, PlayerDatas.Instance.baseData.VIPLv);
         if (countLimit == -1)
         {
             wannaBuyCount.value = Mathf.Clamp(count, 1, 999);
@@ -166,7 +166,7 @@
             return -1;
         }
 
-        var isVipLimitGood = config != null && config.VIPLV.Length > 1 && config.VIPLV[0] > 0;
+        var isVipLimitGood = config != null && config.VIPLV.Length > 1;
         var canBuy = 0;
         if (isVipLimitGood)
         {
@@ -178,8 +178,8 @@
                     index = i;
                     break;
                 }
-            }
-
+            }
+           
             if (index != -1)
             {
                 canBuy = config.PurchaseNumber[index];

--
Gitblit v1.8.0