轩辕宝镜修改

(cherry picked from commit f838e2d0f2)
dev_one_discount hotfix/you_gu/cdn_shanQu_and/1.1.30
wangzhenxing 2023-08-29 15:21:53 +08:00 committed by DESKTOP-RH64908\Administrator
parent 4ade868f90
commit 0dddc2ef7c
1 changed files with 11 additions and 2 deletions

View File

@ -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