降妖夺宝十连抽修改
parent
9f005990d4
commit
8177a8d6cb
|
@ -46,6 +46,13 @@ function TenRecruitPanel:BindEvent()
|
||||||
end)
|
end)
|
||||||
Util.AddClick(self.againBtn, function()
|
Util.AddClick(self.againBtn, function()
|
||||||
local d=RecruitManager.GetExpendData(type)
|
local d=RecruitManager.GetExpendData(type)
|
||||||
|
local MoneyTimes=lotterySetting[type].MoneyTimes
|
||||||
|
local needCostTime=PrivilegeManager.GetPrivilegeUsedTimes(MoneyTimes)+10
|
||||||
|
if d[1] == 16 and needCostTime>privilegeConfig[MoneyTimes].Condition[1][2] then
|
||||||
|
local lotterySettingConfig = ConfigManager.GetConfigData(ConfigName.LotterySetting,type)
|
||||||
|
local costLength=#lotterySettingConfig.CostItem
|
||||||
|
d=lotterySettingConfig.CostItem[costLength]
|
||||||
|
end
|
||||||
if BagManager.GetItemCountById(d[1])<d[2] then
|
if BagManager.GetItemCountById(d[1])<d[2] then
|
||||||
PopupTipPanel.ShowTip(GetLanguageStrById(itemConfig[d[1]].Name)..Language[10486])
|
PopupTipPanel.ShowTip(GetLanguageStrById(itemConfig[d[1]].Name)..Language[10486])
|
||||||
return
|
return
|
||||||
|
@ -122,7 +129,15 @@ function TenRecruitPanel:OnOpen(...)
|
||||||
d=RecruitManager.GetExpendDataByCostItem(Setting.CostItemMul,2,num)
|
d=RecruitManager.GetExpendDataByCostItem(Setting.CostItemMul,2,num)
|
||||||
else
|
else
|
||||||
d=RecruitManager.GetExpendData(type)
|
d=RecruitManager.GetExpendData(type)
|
||||||
|
local MoneyTimes=lotterySetting[type].MoneyTimes
|
||||||
|
local needCostTime=PrivilegeManager.GetPrivilegeUsedTimes(MoneyTimes)+10
|
||||||
|
if d[1] == 16 and needCostTime>privilegeConfig[MoneyTimes].Condition[1][2] then
|
||||||
|
local lotterySettingConfig = ConfigManager.GetConfigData(ConfigName.LotterySetting,type)
|
||||||
|
local costLength=#lotterySettingConfig.CostItem
|
||||||
|
d=lotterySettingConfig.CostItem[costLength]
|
||||||
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
this.againIcon.sprite=this.spLoader:LoadSprite(artResourcesConfig[itemConfig[d[1]].ResourceID].Name)
|
this.againIcon.sprite=this.spLoader:LoadSprite(artResourcesConfig[itemConfig[d[1]].ResourceID].Name)
|
||||||
this.againNum.text="×"..d[2]
|
this.againNum.text="×"..d[2]
|
||||||
maxTimesId=lotterySetting[type].MaxTimes --特权上限ID
|
maxTimesId=lotterySetting[type].MaxTimes --特权上限ID
|
||||||
|
|
Loading…
Reference in New Issue