4230 【BUG】【2.0】显示可购买20个,实际只能买5个
| | |
| | | |
| | | 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); |
| | |
| | | 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) |
| | | { |
| | |
| | | index = i; |
| | | break; |
| | | } |
| | | } |
| | | |
| | | }
|
| | | |
| | | if (index != -1) |
| | | { |
| | | canBuy = config.PurchaseNumber[index]; |