parent
e95f7f9e26
commit
acf33d10a3
|
@ -96,41 +96,11 @@ function MonsterCampNewPanel:BindEvent()
|
||||||
end,2)
|
end,2)
|
||||||
end)
|
end)
|
||||||
Util.AddClick(this.moppingUpBtn, function ()
|
Util.AddClick(this.moppingUpBtn, function ()
|
||||||
-- if MonsterCampManager.monsterWave - 1 <= 0 then
|
local waveConfig = ConfigManager.GetConfigData(ConfigName.FloodConfig,MonsterCampManager.monsterWave)
|
||||||
-- PopupTipPanel.ShowTip("无法扫荡,请先挑战心魔试炼!")
|
if not waveConfig then
|
||||||
-- return
|
PopupTipPanel.ShowTip("已通过最高层,无法快速挑战!")
|
||||||
-- end
|
return
|
||||||
-- if freeTimes <= 0 and buyTimes <= 0 then
|
end
|
||||||
-- PopupTipPanel.ShowTip("今日已无扫荡次数!")
|
|
||||||
-- return
|
|
||||||
-- end
|
|
||||||
-- local _storeDataId,_itemId,_costNum,moppingUpNum = MonsterCampManager.MonsterCampGetYJGMCost()
|
|
||||||
-- MsgPanel.ShowTwo(string.format("是否花费%s%s进行一键扫荡?",_costNum,itemConfig[itemId].Name),function() end,function()
|
|
||||||
-- if BagManager.GetItemCountById(_itemId) < _costNum then
|
|
||||||
-- PopupTipPanel.ShowTip(string.format(Language[10298], itemConfig[itemId].Name))
|
|
||||||
-- else
|
|
||||||
-- if moppingUpNum > 0 then
|
|
||||||
-- ShopManager.RequestBuyShopItem(SHOP_TYPE.FUNCTION_SHOP,storeDataId,moppingUpNum,function()
|
|
||||||
-- PrivilegeManager.RefreshPrivilegeUsedTimes(PRIVILEGE_TYPE.MONSTERCAMP_BUY_BATTLENUM, moppingUpNum)
|
|
||||||
-- NetManager.SweepDemonRequest(MonsterCampManager.monsterWave - 1,true,function(msg)
|
|
||||||
-- UIManager.OpenPanel(UIName.RewardItemPopup,msg.Drop,1,function()
|
|
||||||
-- PrivilegeManager.RefreshPrivilegeUsedTimes(PRIVILEGE_TYPE.MONSTERCAMP_BATTLENUM, MonsterCampManager.GetCanBattleCount() )
|
|
||||||
-- this.UpdatePrivilage()
|
|
||||||
-- end)
|
|
||||||
-- end)
|
|
||||||
-- end)
|
|
||||||
-- else
|
|
||||||
-- NetManager.SweepDemonRequest(MonsterCampManager.monsterWave - 1,true,function(msg)
|
|
||||||
-- UIManager.OpenPanel(UIName.RewardItemPopup,msg.Drop,1,function()
|
|
||||||
-- PrivilegeManager.RefreshPrivilegeUsedTimes(PRIVILEGE_TYPE.MONSTERCAMP_BATTLENUM, MonsterCampManager.GetCanBattleCount() )
|
|
||||||
-- this.UpdatePrivilage()
|
|
||||||
-- end)
|
|
||||||
-- end)
|
|
||||||
-- end
|
|
||||||
|
|
||||||
-- end
|
|
||||||
-- end,"取消","确定")
|
|
||||||
|
|
||||||
if FormationManager.CheckFormationValid(FormationTypeDef.MONSTER_CAMP_ATTACK) then
|
if FormationManager.CheckFormationValid(FormationTypeDef.MONSTER_CAMP_ATTACK) then
|
||||||
this.QuickStartMonsterFightRequest()
|
this.QuickStartMonsterFightRequest()
|
||||||
else
|
else
|
||||||
|
|
|
@ -107,29 +107,37 @@ function this:BindEvent()
|
||||||
local currentTime = os.date("%Y%m%d", PlayerManager.serverTime)
|
local currentTime = os.date("%Y%m%d", PlayerManager.serverTime)
|
||||||
local shopType = localSelf.ShopType
|
local shopType = localSelf.ShopType
|
||||||
local isAutoRecover = ShopManager.IsAutoRecoverCount(shopType)
|
local isAutoRecover = ShopManager.IsAutoRecoverCount(shopType)
|
||||||
if shopType == SHOP_TYPE.SOUL_PRINT_SHOP then
|
local leftCount = this.GetShopLeftRefreshCount(shopType)
|
||||||
local itemlist = ShopManager.CheckShopItemList(self.ShopData.storeItem)
|
if leftCount == -2 then
|
||||||
local isShow = false
|
PopupTipPanel.ShowTip(Language[11896])
|
||||||
for k,v in pairs(itemlist) do
|
elseif leftCount == 0 then
|
||||||
local goods = ShopManager.GetShopItemGoodsInfo(v.id)
|
PopupTipPanel.ShowTip(Language[11897])
|
||||||
local con = ConfigManager.GetConfigData(ConfigName.ItemConfig,goods[1][1])
|
else
|
||||||
if con.Quantity >= 6 then
|
if shopType == SHOP_TYPE.SOUL_PRINT_SHOP then
|
||||||
isShow = true
|
local itemlist = ShopManager.CheckShopItemList(self.ShopData.storeItem)
|
||||||
end
|
local isShow = false
|
||||||
end
|
for k,v in pairs(itemlist) do
|
||||||
if isShow then
|
local goods = ShopManager.GetShopItemGoodsInfo(v.id)
|
||||||
MsgPanel.ShowTwo("当前商店存在红色魂印,刷新后将会消失,是否确认刷新?", function()
|
local itemInfo = ShopManager.GetShopItemInfo(v.id)
|
||||||
end, function()
|
local maxLimitCount = ShopManager.GetShopItemLimitBuyCount(v.id)
|
||||||
|
local curBuyCount = itemInfo.buyNum
|
||||||
|
local con = ConfigManager.GetConfigData(ConfigName.ItemConfig,goods[1][1])
|
||||||
|
if con.Quantity >= 6 and curBuyCount < maxLimitCount then
|
||||||
|
isShow = true
|
||||||
|
end
|
||||||
|
end
|
||||||
|
if isShow then
|
||||||
|
MsgPanel.ShowTwo("当前商店存在红色魂印,刷新后将会消失,是否确认刷新?", function()
|
||||||
|
end, function()
|
||||||
|
RefreshShop(isPopUp,currentTime,isAutoRecover,shopType)
|
||||||
|
end, Language[10731], Language[10732],nil,false)
|
||||||
|
else
|
||||||
RefreshShop(isPopUp,currentTime,isAutoRecover,shopType)
|
RefreshShop(isPopUp,currentTime,isAutoRecover,shopType)
|
||||||
end, Language[10731], Language[10732],nil,false)
|
end
|
||||||
else
|
else
|
||||||
RefreshShop(isPopUp,currentTime,isAutoRecover,shopType)
|
RefreshShop(isPopUp,currentTime,isAutoRecover,shopType)
|
||||||
end
|
end
|
||||||
else
|
|
||||||
RefreshShop(isPopUp,currentTime,isAutoRecover,shopType)
|
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
||||||
-- 重置商店刷新按钮点击状态
|
-- 重置商店刷新按钮点击状态
|
||||||
ShopManager.SetShopRefreshBtnClickStatus(localSelf.ShopType, true)
|
ShopManager.SetShopRefreshBtnClickStatus(localSelf.ShopType, true)
|
||||||
end)
|
end)
|
||||||
|
|
Loading…
Reference in New Issue