【降妖夺宝】取消抽卡前摇

(cherry picked from commit c84656e705)
dev_chengFeng
ZhangBiao 2020-12-29 14:51:30 +08:00 committed by zhangqiang
parent d09bc60b5e
commit 4a90f8838e
1 changed files with 17 additions and 1 deletions

View File

@ -61,6 +61,9 @@ end
function SingleRecruitPanel:BindEvent()
Util.AddClick(self.sureBtn, function()
isFirst=true
if lotterySetting[type].LotteryType == 11 then
isFirst=false
end
self:ClosePanel()
if PlayerManager.IsGetFiveStarHero then--and OperatingManager.IsShowFiveStarPatch then
Game.GlobalEvent:DispatchEvent(GameEvent.PatFace.PatFaceSend, FacePanelType.GrowGift, 5)
@ -111,6 +114,9 @@ function SingleRecruitPanel:BindEvent()
--十连跳过按钮 直接打开十连抽展示界面
Util.AddClick(self.jumpBtn, function()
isFirst=true
if lotterySetting[type].LotteryType == 11 then
isFirst=false
end
self:ClosePanel()
UIManager.OpenPanel(UIName.TenRecruitPanel,heroData,type,recruitType)
end)
@ -124,6 +130,9 @@ function SingleRecruitPanel:BindEvent()
elseif state==2 then
if index>=LengthOfTable(_heroTable) then
isFirst=true
if lotterySetting[type].LotteryType == 11 then
isFirst=false
end
self:ClosePanel()
UIManager.OpenPanel(UIName.TenRecruitPanel,heroData,type,recruitType)
else
@ -165,12 +174,19 @@ function SingleRecruitPanel:OnOpen(...)
recruitType=data[4]
end
function SingleRecruitPanel:OnShow()
isFirst=true
maxTimesId=lotterySetting[type].MaxTimes --特权上限ID
index=0
if state==1 then --单抽
if lotterySetting[type].LotteryType == 11 then
isFirst=false
end
self:TenOpenPanel()
elseif state==2 then
isFirst=true
if lotterySetting[type].LotteryType == 11 then
isFirst=false
end
_heroTable={}
--将符合条件的英雄插入容器中
for k, v in ipairs(heroData) do