From 0dddc2ef7c1862c9182dc0e57a95a534a5cfa493 Mon Sep 17 00:00:00 2001 From: wangzhenxing <1545929779@qq.com> Date: Tue, 29 Aug 2023 15:21:53 +0800 Subject: [PATCH] =?UTF-8?q?=E8=BD=A9=E8=BE=95=E5=AE=9D=E9=95=9C=E4=BF=AE?= =?UTF-8?q?=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit (cherry picked from commit f838e2d0f2d50a2535053197d77c1f2aeaeec6ac) --- .../~Lua/Modules/Carbon/XuanYuanMirrorPanelList.lua | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/Assets/ManagedResources/~Lua/Modules/Carbon/XuanYuanMirrorPanelList.lua b/Assets/ManagedResources/~Lua/Modules/Carbon/XuanYuanMirrorPanelList.lua index a49d64262e..d8bb7913f9 100644 --- a/Assets/ManagedResources/~Lua/Modules/Carbon/XuanYuanMirrorPanelList.lua +++ b/Assets/ManagedResources/~Lua/Modules/Carbon/XuanYuanMirrorPanelList.lua @@ -242,7 +242,8 @@ function this:SetLevelData(go, data) PopupTipPanel.ShowTip(Language[10297]) return end - + LogError("costnum==="..costNum) + LogError("XuanYuanMirrorManager.freeTime="..XuanYuanMirrorManager.freeTime) if BagManager.GetItemCountById(itemId) < costNum and XuanYuanMirrorManager.freeTime <= 0 then PopupTipPanel.ShowTip(string.format(Language[10298], GetLanguageStrById(itemConfig[itemId].Name))) return @@ -340,8 +341,16 @@ function this:OnShow(...) local usedTimes=PrivilegeManager.GetPrivilegeUsedTimes(buyTimeId) local privilegeTime=PrivilegeManager.GetPrivilegeNumber(buyTimeId) --商店表数据 + LogError("usedtimes=="..usedTimes.." privegetime=="..privilegeTime) local buyTimes = usedTimes>= privilegeTime and privilegeTime or usedTimes+1 - costNum = storeData.Cost[2][buyTimes] + LogError("bugytimes=="..buyTimeId.." buytimes=="..buyTimes) + if buyTimes==0 then + costNum=0 + else + costNum = storeData.Cost[2][buyTimes] + end + + LogError("-----------------costnum=="..costNum) this:SwitchView(args[1]) end