Merge branch 'china/dev-c' of http://60.1.1.230/gaoxin/JL_Client into china/dev-c
commit
3a698539a9
|
@ -7725,9 +7725,9 @@ RectTransform:
|
||||||
m_Father: {fileID: 7816124763777208762}
|
m_Father: {fileID: 7816124763777208762}
|
||||||
m_RootOrder: 7
|
m_RootOrder: 7
|
||||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||||
m_AnchorMin: {x: 0.5, y: 0.5}
|
m_AnchorMin: {x: 1, y: 1}
|
||||||
m_AnchorMax: {x: 0.5, y: 0.5}
|
m_AnchorMax: {x: 1, y: 1}
|
||||||
m_AnchoredPosition: {x: 448.4, y: 749.7}
|
m_AnchoredPosition: {x: -88, y: -210.29999}
|
||||||
m_SizeDelta: {x: 128, y: 126}
|
m_SizeDelta: {x: 128, y: 126}
|
||||||
m_Pivot: {x: 0.5, y: 0.5}
|
m_Pivot: {x: 0.5, y: 0.5}
|
||||||
--- !u!222 &5589450041689530360
|
--- !u!222 &5589450041689530360
|
||||||
|
@ -8419,7 +8419,7 @@ RectTransform:
|
||||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||||
m_AnchorMin: {x: 1, y: 1}
|
m_AnchorMin: {x: 1, y: 1}
|
||||||
m_AnchorMax: {x: 1, y: 1}
|
m_AnchorMax: {x: 1, y: 1}
|
||||||
m_AnchoredPosition: {x: -48, y: -473.59998}
|
m_AnchoredPosition: {x: -88, y: -473.59998}
|
||||||
m_SizeDelta: {x: 71.599976, y: 69.92993}
|
m_SizeDelta: {x: 71.599976, y: 69.92993}
|
||||||
m_Pivot: {x: 0.5, y: 0.5}
|
m_Pivot: {x: 0.5, y: 0.5}
|
||||||
--- !u!222 &7359118887627014995
|
--- !u!222 &7359118887627014995
|
||||||
|
|
|
@ -437,8 +437,8 @@ SubUIConfig = {
|
||||||
[14] = {name = "ExChangePage",assetName = "ExChangePage",script = "Modules/NewActivity/ExChangePage"},--限时兑换界面预设
|
[14] = {name = "ExChangePage",assetName = "ExChangePage",script = "Modules/NewActivity/ExChangePage"},--限时兑换界面预设
|
||||||
|
|
||||||
[15] = {name = "page2",assetName = "page2",script = "Modules/DynamicActivity/SheJiDaDian"}, --社稷大典
|
[15] = {name = "page2",assetName = "page2",script = "Modules/DynamicActivity/SheJiDaDian"}, --社稷大典
|
||||||
[16] = {name = "TimeLimitUpHero",assetName = "TimeLimitUpHero",script = "Modules/DynamicActivity/TimeLimitUpHero"}, --限时召唤
|
--[16] = {name = "TimeLimitUpHero",assetName = "TimeLimitUpHero",script = "Modules/DynamicActivity/TimeLimitUpHero"}, --限时召唤
|
||||||
--[16] = {name = "page3",assetName = "page3",script = "Modules/DynamicActivity/TimeLimitedCall"}, --限时召唤
|
[16] = {name = "page3",assetName = "page3",script = "Modules/DynamicActivity/TimeLimitedCall"}, --限时召唤
|
||||||
[17] = {name = "page4",assetName = "page4",script = "Modules/DynamicActivity/QianKunBox"},--乾坤宝盒
|
[17] = {name = "page4",assetName = "page4",script = "Modules/DynamicActivity/QianKunBox"},--乾坤宝盒
|
||||||
[18] = {name = "page9",assetName = "page9",script = "Modules/DynamicActivity/YiJingBaoKu"},--易经宝库
|
[18] = {name = "page9",assetName = "page9",script = "Modules/DynamicActivity/YiJingBaoKu"},--易经宝库
|
||||||
[19] = {name = "page10",assetName = "page10",script = "Modules/DynamicActivity/ShengYiTianJiang"},--神衣天降
|
[19] = {name = "page10",assetName = "page10",script = "Modules/DynamicActivity/ShengYiTianJiang"},--神衣天降
|
||||||
|
@ -449,5 +449,5 @@ SubUIConfig = {
|
||||||
[24] = { name = "ShopView", assetName = "ShopView", script = "View/ShopViewNew" },
|
[24] = { name = "ShopView", assetName = "ShopView", script = "View/ShopViewNew" },
|
||||||
[25] = { name = "FuXingGaoZhaoPanel", assetName = "FuXingGaoZhaoPanel", script = "Modules/FuXingGaoZhao/FuXingGaoZhaoPanel" },
|
[25] = { name = "FuXingGaoZhaoPanel", assetName = "FuXingGaoZhaoPanel", script = "Modules/FuXingGaoZhao/FuXingGaoZhaoPanel" },
|
||||||
[26] = { name = "NiuQiChongTianPanel", assetName = "NiuQiChongTianPanel", script = "Modules/NiuQiChongTian/NiuQiChongTianPanel" },
|
[26] = { name = "NiuQiChongTianPanel", assetName = "NiuQiChongTianPanel", script = "Modules/NiuQiChongTian/NiuQiChongTianPanel" },
|
||||||
--[27] = {name = "TimeLimitUpHero",assetName = "TimeLimitUpHero",script = "Modules/DynamicActivity/TimeLimitUpHero"}, --限时英雄up界面
|
[27] = {name = "TimeLimitUpHero",assetName = "TimeLimitUpHero",script = "Modules/DynamicActivity/TimeLimitUpHero"}, --限时英雄up界面
|
||||||
}
|
}
|
|
@ -132,7 +132,8 @@ function QianKunBoxBuyOnePanel:OnOpen(...)
|
||||||
local wish=ConfigManager.GetConfigData(ConfigName.WishActivitySetting,1)
|
local wish=ConfigManager.GetConfigData(ConfigName.WishActivitySetting,1)
|
||||||
if wish then
|
if wish then
|
||||||
this.UpView:OnOpen({ showType = UpViewOpenType.ShowLeft, panelType = PanelType.TimelimitCall })
|
this.UpView:OnOpen({ showType = UpViewOpenType.ShowLeft, panelType = PanelType.TimelimitCall })
|
||||||
d = RecruitManager.GetExpendDataByCostItem(wish.CostItemSingle)
|
local num=PrivilegeManager.GetPrivilegeRemainValue(wish.DiamondMaxTimes)
|
||||||
|
d = RecruitManager.GetExpendDataByCostItem(wish.CostItemSingle,1,num)
|
||||||
isLimitUpHero=true
|
isLimitUpHero=true
|
||||||
end
|
end
|
||||||
else
|
else
|
||||||
|
|
|
@ -24,7 +24,7 @@ local isLimitUpHero=false
|
||||||
--初始化组件(用于子类重写)
|
--初始化组件(用于子类重写)
|
||||||
function QianKunBoxBuyTenPanel:InitComponent()
|
function QianKunBoxBuyTenPanel:InitComponent()
|
||||||
this.spLoader = SpriteLoader.New()
|
this.spLoader = SpriteLoader.New()
|
||||||
|
this.UpView = SubUIManager.Open(SubUIConfig.UpView, self.gameObject.transform, { showType = UpViewOpenType.ShowLeft, panelType = PanelType.ElementDrawCard })
|
||||||
orginLayer = 0
|
orginLayer = 0
|
||||||
self.bg = Util.GetGameObject(self.gameObject, "effect")
|
self.bg = Util.GetGameObject(self.gameObject, "effect")
|
||||||
screenAdapte(self.bg)
|
screenAdapte(self.bg)
|
||||||
|
@ -44,7 +44,7 @@ function QianKunBoxBuyTenPanel:InitComponent()
|
||||||
this.detailImage3=Util.GetGameObject(this.content3, "Tip")
|
this.detailImage3=Util.GetGameObject(this.content3, "Tip")
|
||||||
this.itemIcon3=Util.GetGameObject(this.content3, "icon"):GetComponent("Image")
|
this.itemIcon3=Util.GetGameObject(this.content3, "icon"):GetComponent("Image")
|
||||||
this.itemNum3=Util.GetGameObject(this.content3, "num"):GetComponent("Text")
|
this.itemNum3=Util.GetGameObject(this.content3, "num"):GetComponent("Text")
|
||||||
|
this.itemInfo3=Util.GetGameObject(this.content3, "info"):GetComponent("Text")
|
||||||
this.content2=Util.GetGameObject(self.gameObject,"bottom/openTenAgainButton/Content2")
|
this.content2=Util.GetGameObject(self.gameObject,"bottom/openTenAgainButton/Content2")
|
||||||
this.itemIcon2=Util.GetGameObject(this.content2,"Icon"):GetComponent("Image")
|
this.itemIcon2=Util.GetGameObject(this.content2,"Icon"):GetComponent("Image")
|
||||||
this.itemNum2=Util.GetGameObject(this.content2,"Num"):GetComponent("Text")
|
this.itemNum2=Util.GetGameObject(this.content2,"Num"):GetComponent("Text")
|
||||||
|
@ -143,15 +143,19 @@ function QianKunBoxBuyTenPanel:OnOpen(...)
|
||||||
local itemId=0
|
local itemId=0
|
||||||
local itemNum=0
|
local itemNum=0
|
||||||
local d
|
local d
|
||||||
local upConfig=ConfigManager.GetConfigDataByKey(ConfigName.WishActivityUp,"ActivityId",this.recruitType)
|
local upConfig=ConfigManager.TryGetConfigDataByKey(ConfigName.WishActivityUp,"ActivityId",this.recruitType)
|
||||||
if upConfig then
|
if upConfig then
|
||||||
local wish=ConfigManager.GetConfigData(ConfigName.WishActivitySetting,1)
|
local wish=ConfigManager.GetConfigData(ConfigName.WishActivitySetting,1)
|
||||||
if wish then
|
if wish then
|
||||||
|
this.UpView:OnOpen({ showType = UpViewOpenType.ShowLeft, panelType = PanelType.TimelimitCall })
|
||||||
isLimitUpHero=true
|
isLimitUpHero=true
|
||||||
d = RecruitManager.GetExpendDataByCostItem(wish.CostItemMul)
|
this.itemInfo3.text="10次"
|
||||||
|
local num=PrivilegeManager.GetPrivilegeRemainValue(wish.DiamondMaxTimes)
|
||||||
|
d = RecruitManager.GetExpendDataByCostItem(wish.CostItemMul,2,num)
|
||||||
end
|
end
|
||||||
else
|
else
|
||||||
d = RecruitManager.GetExpendData(this.recruitType)
|
d = RecruitManager.GetExpendData(this.recruitType)
|
||||||
|
SubUIManager.Close(this.UpView)
|
||||||
end
|
end
|
||||||
itemId=d[1]
|
itemId=d[1]
|
||||||
itemNum=d[2]
|
itemNum=d[2]
|
||||||
|
@ -211,6 +215,7 @@ end
|
||||||
--界面销毁时调用(用于子类重写)
|
--界面销毁时调用(用于子类重写)
|
||||||
function QianKunBoxBuyTenPanel:OnDestroy()
|
function QianKunBoxBuyTenPanel:OnDestroy()
|
||||||
this.spLoader:Destroy()
|
this.spLoader:Destroy()
|
||||||
|
SubUIManager.Close(this.UpView)
|
||||||
this.views = nil
|
this.views = nil
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
|
@ -23,6 +23,7 @@ local Setting=nil
|
||||||
local oneFunc=nil
|
local oneFunc=nil
|
||||||
local tenFunc=nil
|
local tenFunc=nil
|
||||||
local oneFunc2=nil
|
local oneFunc2=nil
|
||||||
|
local isYaojing=false
|
||||||
--初始化组件(用于子类重写)
|
--初始化组件(用于子类重写)
|
||||||
function TimeLimitUpHero:InitComponent()
|
function TimeLimitUpHero:InitComponent()
|
||||||
self.spLoader = SpriteLoader.New()
|
self.spLoader = SpriteLoader.New()
|
||||||
|
@ -80,6 +81,7 @@ function TimeLimitUpHero:InitComponent()
|
||||||
local SkeletonGraphic = heroLiveObj:GetComponent("SkeletonGraphic")
|
local SkeletonGraphic = heroLiveObj:GetComponent("SkeletonGraphic")
|
||||||
SkeletonGraphic.AnimationState:SetAnimation(0, "touch", false)
|
SkeletonGraphic.AnimationState:SetAnimation(0, "touch", false)
|
||||||
end)
|
end)
|
||||||
|
|
||||||
end
|
end
|
||||||
|
|
||||||
--绑定事件(用于子类重写)
|
--绑定事件(用于子类重写)
|
||||||
|
@ -141,7 +143,6 @@ function TimeLimitUpHero:OnShow(_sortingOrder)
|
||||||
for k,v in ipairs(self.bgs) do
|
for k,v in ipairs(self.bgs) do
|
||||||
v.bg.gameObject:SetActive(false)
|
v.bg.gameObject:SetActive(false)
|
||||||
end
|
end
|
||||||
LogError("actId "..self.actId)
|
|
||||||
wishConfig=ConfigManager.GetConfigDataByKey(ConfigName.WishActivityUp,"ActivityId",self.actId)
|
wishConfig=ConfigManager.GetConfigDataByKey(ConfigName.WishActivityUp,"ActivityId",self.actId)
|
||||||
self.titleImg.sprite=self.spLoader:LoadSprite(self.actConfig.Icon[3])
|
self.titleImg.sprite=self.spLoader:LoadSprite(self.actConfig.Icon[3])
|
||||||
Setting= ConfigManager.GetConfigData(ConfigName.WishActivitySetting,1)
|
Setting= ConfigManager.GetConfigData(ConfigName.WishActivitySetting,1)
|
||||||
|
@ -150,6 +151,8 @@ function TimeLimitUpHero:OnShow(_sortingOrder)
|
||||||
self.yaojingMaxTimeId =Setting.DiamondMaxTimes
|
self.yaojingMaxTimeId =Setting.DiamondMaxTimes
|
||||||
activityData=ActivityGiftManager.GetActivityInfoByType(self.actId)
|
activityData=ActivityGiftManager.GetActivityInfoByType(self.actId)
|
||||||
curHeroId=activityData.choiceRewardId
|
curHeroId=activityData.choiceRewardId
|
||||||
|
local curTimes = PrivilegeManager.GetPrivilegeUsedTimes(self.maxtimesId)
|
||||||
|
self.upper.text= "今日召唤上限:"..curTimes.."/"..privilegeConfig[self.maxtimesId].Condition[1][2]--特权上限
|
||||||
LogError("活动数据英雄id: "..activityData.choiceRewardId)
|
LogError("活动数据英雄id: "..activityData.choiceRewardId)
|
||||||
self:RefreshHeroData()
|
self:RefreshHeroData()
|
||||||
self:RefreshGetHeroTimes()
|
self:RefreshGetHeroTimes()
|
||||||
|
@ -166,25 +169,22 @@ function TimeLimitUpHero:RefreshHeroData()
|
||||||
poolManager:UnLoadLive(lastLiveName, heroLiveObj)
|
poolManager:UnLoadLive(lastLiveName, heroLiveObj)
|
||||||
end
|
end
|
||||||
lastLiveName=GetResourcePath(curConfig.Live)
|
lastLiveName=GetResourcePath(curConfig.Live)
|
||||||
LogError("lastLiveName=="..lastLiveName)
|
|
||||||
heroLiveObj=HeroManager.LoadHerolive1(curConfig,self.heroPar)
|
heroLiveObj=HeroManager.LoadHerolive1(curConfig,self.heroPar)
|
||||||
|
|
||||||
|
|
||||||
end
|
end
|
||||||
local isYaojing=false
|
|
||||||
local freeTime = 0
|
local freeTime = 0
|
||||||
--刷新剩余次数
|
--刷新剩余次数
|
||||||
function TimeLimitUpHero:RefreshGetHeroTimes()
|
function TimeLimitUpHero:RefreshGetHeroTimes()
|
||||||
local curTimes = PrivilegeManager.GetPrivilegeUsedTimes(self.maxtimesId)
|
|
||||||
self.upper.text= "今日召唤上限:"..curTimes.."/"..privilegeConfig[self.maxtimesId].Condition[1][2]--特权上限
|
|
||||||
self.timeupdate.gameObject:SetActive(true)
|
self.timeupdate.gameObject:SetActive(true)
|
||||||
if self.freeTimesId and self.freeTimesId > 0 then
|
if self.freeTimesId and self.freeTimesId > 0 then
|
||||||
freeTime = PrivilegeManager.GetPrivilegeRemainValue(self.freeTimesId)
|
freeTime = PrivilegeManager.GetPrivilegeRemainValue(self.freeTimesId)
|
||||||
LogError("self freetimes "..freeTime)
|
|
||||||
RecruitManager.freeUseTimeList[self.freeTimesId]=freeTime
|
RecruitManager.freeUseTimeList[self.freeTimesId]=freeTime
|
||||||
end
|
end
|
||||||
--按钮赋值
|
--按钮赋值
|
||||||
|
local num=PrivilegeManager.GetPrivilegeRemainValue(Setting.DiamondMaxTimes)
|
||||||
|
self.recruitTimesUpdate.text = string.format("今日剩余妖晶召唤次数:<color=#F27D0F>%s</color>",num)
|
||||||
for n, m in ipairs(self.btns) do
|
for n, m in ipairs(self.btns) do
|
||||||
--存在免费次数 并且 免费>=1 并且是1按钮
|
--存在免费次数 并且 免费>=1 并且是1按钮
|
||||||
local isFree = freeTime >= 1 and n == 1
|
local isFree = freeTime >= 1 and n == 1
|
||||||
|
@ -206,7 +206,7 @@ function TimeLimitUpHero:RefreshGetHeroTimes()
|
||||||
self.timeupdate.gameObject:SetActive(false)
|
self.timeupdate.gameObject:SetActive(false)
|
||||||
m.info.text="免费抽取"
|
m.info.text="免费抽取"
|
||||||
else
|
else
|
||||||
local d = RecruitManager.GetExpendDataByCostItem(type)
|
local d = RecruitManager.GetExpendDataByCostItem(type,n,num)
|
||||||
itemId=d[1]
|
itemId=d[1]
|
||||||
if itemId==16 then
|
if itemId==16 then
|
||||||
isYaojing=true
|
isYaojing=true
|
||||||
|
@ -216,8 +216,12 @@ function TimeLimitUpHero:RefreshGetHeroTimes()
|
||||||
m.num.text= tostring(itemNum)
|
m.num.text= tostring(itemNum)
|
||||||
end
|
end
|
||||||
local sureFunc=function()
|
local sureFunc=function()
|
||||||
|
local isFree = PrivilegeManager.GetPrivilegeRemainValue(self.freeTimesId)>= 1 and n == 1
|
||||||
if not isFree then
|
if not isFree then
|
||||||
if BagManager.GetItemCountById(itemId)<itemNum then
|
local count=PrivilegeManager.GetPrivilegeRemainValue(Setting.DiamondMaxTimes)
|
||||||
|
local d = RecruitManager.GetExpendDataByCostItem(type,n,count)
|
||||||
|
itemId=d[1]
|
||||||
|
if BagManager.GetItemCountById(itemId)<d[2] then
|
||||||
PopupTipPanel.ShowTip(itemConfig[itemId].Name.."数量不足!")
|
PopupTipPanel.ShowTip(itemConfig[itemId].Name.."数量不足!")
|
||||||
return
|
return
|
||||||
end
|
end
|
||||||
|
@ -227,10 +231,10 @@ function TimeLimitUpHero:RefreshGetHeroTimes()
|
||||||
local recrutNum = n == 1 and 1 or 10
|
local recrutNum = n == 1 and 1 or 10
|
||||||
if state==0 and itemId == 16 and not isFree then
|
if state==0 and itemId == 16 and not isFree then
|
||||||
UIManager.OpenPanel(UIName.GeneralPopup,GENERAL_POPUP_TYPE.RecruitConfirm,"timeLimitHero",function()
|
UIManager.OpenPanel(UIName.GeneralPopup,GENERAL_POPUP_TYPE.RecruitConfirm,"timeLimitHero",function()
|
||||||
self:Recruit(self.actId,n)
|
self:Recruit(self.actId,n,itemId)
|
||||||
end,n)
|
end,n)
|
||||||
else
|
else
|
||||||
self:Recruit(self.actId,n)
|
self:Recruit(self.actId,n,itemId)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
if n==1 then
|
if n==1 then
|
||||||
|
@ -241,8 +245,6 @@ function TimeLimitUpHero:RefreshGetHeroTimes()
|
||||||
end
|
end
|
||||||
Util.AddOnceClick(m.btn,sureFunc)
|
Util.AddOnceClick(m.btn,sureFunc)
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
||||||
local reMaintimes = ActivityGiftManager.GetActivityValueInfo(self.actId)
|
local reMaintimes = ActivityGiftManager.GetActivityValueInfo(self.actId)
|
||||||
local totalTimes = 0
|
local totalTimes = 0
|
||||||
for i = 1, #wishConfig.UpList do
|
for i = 1, #wishConfig.UpList do
|
||||||
|
@ -255,12 +257,10 @@ function TimeLimitUpHero:RefreshGetHeroTimes()
|
||||||
reMaintimes = totalTimes
|
reMaintimes = totalTimes
|
||||||
end
|
end
|
||||||
|
|
||||||
local num=PrivilegeManager.GetPrivilegeRemainValue(Setting.DiamondMaxTimes)
|
|
||||||
self.recruitTimesUpdate.text = string.format("今日剩余妖晶召唤次数:<color=#F27D0F>%s</color>",num)
|
|
||||||
self.callTimeTxt.text=reMaintimes
|
self.callTimeTxt.text=reMaintimes
|
||||||
end
|
end
|
||||||
|
|
||||||
function TimeLimitUpHero:Recruit(actId,type)
|
function TimeLimitUpHero:Recruit(actId,type,itemId)
|
||||||
local recrutType =type==1 and 1 or 10
|
local recrutType =type==1 and 1 or 10
|
||||||
if PrivilegeManager.GetPrivilegeUsedTimes(self.maxtimesId)+recrutType>privilegeConfig[self.maxtimesId].Condition[1][2] then
|
if PrivilegeManager.GetPrivilegeUsedTimes(self.maxtimesId)+recrutType>privilegeConfig[self.maxtimesId].Condition[1][2] then
|
||||||
PopupTipPanel.ShowTip("无法超出每日召唤次数上限!")
|
PopupTipPanel.ShowTip("无法超出每日召唤次数上限!")
|
||||||
|
@ -271,29 +271,20 @@ function TimeLimitUpHero:Recruit(actId,type)
|
||||||
PrivilegeManager.RefreshPrivilegeUsedTimes(self.freeTimesId,recrutType)--记录抽卡次数
|
PrivilegeManager.RefreshPrivilegeUsedTimes(self.freeTimesId,recrutType)--记录抽卡次数
|
||||||
end
|
end
|
||||||
PrivilegeManager.RefreshPrivilegeUsedTimes(self.maxtimesId,recrutType)--记录抽卡次数
|
PrivilegeManager.RefreshPrivilegeUsedTimes(self.maxtimesId,recrutType)--记录抽卡次数
|
||||||
-- if then
|
|
||||||
-- freeTime = PrivilegeManager.GetPrivilegeRemainValue(self.freeTimesId)
|
|
||||||
-- end
|
|
||||||
|
|
||||||
--记录妖晶抽卡
|
--记录妖晶抽卡
|
||||||
if isYaojing then
|
if itemId==16 then
|
||||||
|
LogError("记录妖晶次数")
|
||||||
PrivilegeManager.RefreshPrivilegeUsedTimes(self.yaojingMaxTimeId,recrutType)--记录妖晶抽卡次数
|
PrivilegeManager.RefreshPrivilegeUsedTimes(self.yaojingMaxTimeId,recrutType)--记录妖晶抽卡次数
|
||||||
end
|
end
|
||||||
if type == 1 then
|
if type == 1 then
|
||||||
LogError("len=="..LengthOfTable(msg.drop.Hero))
|
|
||||||
local data=msg.drop.Hero
|
|
||||||
if oneFunc then
|
|
||||||
LogError(" one func ==")
|
|
||||||
end
|
|
||||||
UIManager.OpenPanel(UIName.QianKunBoxBuyOnePanel, msg.drop,actId,{RecruitType.PrayerSingle,RecruitType.PrayerTen},oneFunc)
|
UIManager.OpenPanel(UIName.QianKunBoxBuyOnePanel, msg.drop,actId,{RecruitType.PrayerSingle,RecruitType.PrayerTen},oneFunc)
|
||||||
else
|
else
|
||||||
--UIManager.OpenPanel(UIName.SingleRecruitPanel, msg.drop.Hero,actId,type,{RecruitType.TimeLimitSingle,RecruitType.TimeLimitTen})
|
--UIManager.OpenPanel(UIName.SingleRecruitPanel, msg.drop.Hero,actId,type,{RecruitType.TimeLimitSingle,RecruitType.TimeLimitTen})
|
||||||
UIManager.OpenPanel(UIName.QianKunBoxBuyTenPanel, msg.drop,actId,{RecruitType.PrayerSingle,RecruitType.PrayerTen},tenFunc)
|
UIManager.OpenPanel(UIName.QianKunBoxBuyTenPanel, msg.drop,actId,{RecruitType.PrayerSingle,RecruitType.PrayerTen},tenFunc)
|
||||||
end
|
end
|
||||||
if msg.drop.Hero[1] then
|
if msg.drop.Hero[1] then
|
||||||
if not oneFunc then
|
|
||||||
LogError(" one func ==nil")
|
|
||||||
end
|
|
||||||
UIManager.OpenPanel(UIName.SingleRecruitPanel, msg.drop.Hero[1],actId,1,{RecruitType.TimeLimitSingle,RecruitType.TimeLimitTen},oneFunc2)
|
UIManager.OpenPanel(UIName.SingleRecruitPanel, msg.drop.Hero[1],actId,1,{RecruitType.TimeLimitSingle,RecruitType.TimeLimitTen},oneFunc2)
|
||||||
end
|
end
|
||||||
CheckRedPointStatus(RedPointType.TimeLimited)
|
CheckRedPointStatus(RedPointType.TimeLimited)
|
||||||
|
|
|
@ -11,7 +11,7 @@ end
|
||||||
|
|
||||||
function this.MakeAEmptyTeam(teamId)
|
function this.MakeAEmptyTeam(teamId)
|
||||||
local oTeam = {}
|
local oTeam = {}
|
||||||
Log("TeamId" .. teamId)
|
-- Log("TeamId" .. teamId)
|
||||||
oTeam.teamId = teamId
|
oTeam.teamId = teamId
|
||||||
if teamId < FormationTypeDef.FORMATION_ARENA_DEFEND then
|
if teamId < FormationTypeDef.FORMATION_ARENA_DEFEND then
|
||||||
oTeam.teamName = Language[10676]--Language[10677] .. tostring(teamId)
|
oTeam.teamName = Language[10676]--Language[10677] .. tostring(teamId)
|
||||||
|
|
|
@ -71,6 +71,12 @@ function this.OnFunctionOpen(funcId)
|
||||||
end
|
end
|
||||||
--LogGreen(tostring(AppConst.isGuide))
|
--LogGreen(tostring(AppConst.isGuide))
|
||||||
local guideId = GlobalSystemConfig[funcId].GuideId
|
local guideId = GlobalSystemConfig[funcId].GuideId
|
||||||
|
if GuideConfig[guideId].IsOpen > 0 then
|
||||||
|
if not ActivityGiftManager.IsActivityTypeOpen(ActivityGiftManager.GetActivityTypeFromId(GuideConfig[guideId].IsOpen)) then
|
||||||
|
Log("活动:"..tostring(GuideConfig[guideId].IsOpen).."未开启,引导Id:"..guideId.."未执行!")
|
||||||
|
return
|
||||||
|
end
|
||||||
|
end
|
||||||
if guideId and guideId ~= 0 and not funcDic[guideId] then
|
if guideId and guideId ~= 0 and not funcDic[guideId] then
|
||||||
table.insert(_FuncGuideList, guideId)
|
table.insert(_FuncGuideList, guideId)
|
||||||
end
|
end
|
||||||
|
|
|
@ -72,7 +72,7 @@ function this.InitHeroData(_msgHeroList)
|
||||||
this.heroResolveLicence[tonumber(hero_resolve_licence[i])] = tonumber(hero_resolve_licence[i])
|
this.heroResolveLicence[tonumber(hero_resolve_licence[i])] = tonumber(hero_resolve_licence[i])
|
||||||
end
|
end
|
||||||
this.UpdateHeroLvEnd()
|
this.UpdateHeroLvEnd()
|
||||||
Log("服务端推送英雄数量:" .. #_msgHeroList)
|
-- Log("服务端推送英雄数量:" .. #_msgHeroList)
|
||||||
for i = 1, #_msgHeroList do
|
for i = 1, #_msgHeroList do
|
||||||
this.UpdateHeroDatas(_msgHeroList[i], true)
|
this.UpdateHeroDatas(_msgHeroList[i], true)
|
||||||
end
|
end
|
||||||
|
@ -2599,7 +2599,7 @@ function this.GetHeroReturnItems2(ShowItemlist, allRewardData)
|
||||||
local curReward = {}
|
local curReward = {}
|
||||||
curReward.id = ShowItemlist[i][1]
|
curReward.id = ShowItemlist[i][1]
|
||||||
curReward.num = ShowItemlist[i][2]
|
curReward.num = ShowItemlist[i][2]
|
||||||
LogBlue("curReward.id:"..curReward.id.." curReward.num"..curReward.num)
|
-- LogBlue("curReward.id:"..curReward.id.." curReward.num"..curReward.num)
|
||||||
curReward.itemConfig = itemConfig[curReward.id]
|
curReward.itemConfig = itemConfig[curReward.id]
|
||||||
if allRewardData[curReward.id] == nil then
|
if allRewardData[curReward.id] == nil then
|
||||||
allRewardData[curReward.id] = curReward
|
allRewardData[curReward.id] = curReward
|
||||||
|
|
|
@ -630,7 +630,7 @@ end
|
||||||
-----------++++++++++++++++++++++++++++++++++++++++ socket +++++++++++++++++++++++++++++
|
-----------++++++++++++++++++++++++++++++++++++++++ socket +++++++++++++++++++++++++++++
|
||||||
-- 请求连接socket
|
-- 请求连接socket
|
||||||
function this.RequestSocketLogin()
|
function this.RequestSocketLogin()
|
||||||
LogRed("请求连接Socket")
|
Log("请求连接Socket")
|
||||||
RequestPanel.Show(Language[11143])
|
RequestPanel.Show(Language[11143])
|
||||||
SocketManager.Disconnect(SocketType.LOGIN)
|
SocketManager.Disconnect(SocketType.LOGIN)
|
||||||
SocketManager.AddNetwork(SocketType.LOGIN, LoginManager.SocketAddress, LoginManager.SocketPort)
|
SocketManager.AddNetwork(SocketType.LOGIN, LoginManager.SocketAddress, LoginManager.SocketPort)
|
||||||
|
|
|
@ -115,7 +115,7 @@ function this.PlayerInfoRequest(func)
|
||||||
PlayerManager.userCreateTime = msg.userCreateTime
|
PlayerManager.userCreateTime = msg.userCreateTime
|
||||||
PatFaceManager.SetisFirstLogVal(msg.isDayFirst)
|
PatFaceManager.SetisFirstLogVal(msg.isDayFirst)
|
||||||
SoulPrintManager.soulEquipPool = msg.SoulEquipPool
|
SoulPrintManager.soulEquipPool = msg.SoulEquipPool
|
||||||
LogBlue("msg.player.designation "..msg.player.designation.." msg.player.decrotion "..msg.player.decrotion.." msg.player.ride "..msg.player.ride)
|
Log("msg.player.designation "..msg.player.designation.." msg.player.decrotion "..msg.player.decrotion.." msg.player.ride "..msg.player.ride)
|
||||||
PlayerManager.designation = msg.player.designation--称号
|
PlayerManager.designation = msg.player.designation--称号
|
||||||
PlayerManager.skin = msg.player.decrotion--皮肤
|
PlayerManager.skin = msg.player.decrotion--皮肤
|
||||||
PlayerManager.ride = msg.player.ride--坐骑
|
PlayerManager.ride = msg.player.ride--坐骑
|
||||||
|
|
|
@ -63,12 +63,13 @@ function this:OnShow(_parent,...)
|
||||||
this.rootText.text = string.format(Language[11595],_args[3])
|
this.rootText.text = string.format(Language[11595],_args[3])
|
||||||
elseif _args[1] =="timeLimitHero" then
|
elseif _args[1] =="timeLimitHero" then
|
||||||
local wishSettingConfig=ConfigManager.GetConfigData(ConfigName.WishActivitySetting,1)
|
local wishSettingConfig=ConfigManager.GetConfigData(ConfigName.WishActivitySetting,1)
|
||||||
|
local num=PrivilegeManager.GetPrivilegeRemainValue(wishSettingConfig.DiamondMaxTimes)
|
||||||
var = PlayerManager.uid.."GeneralPopup_RecruitConfirm"..RecruitType.PrayerTen
|
var = PlayerManager.uid.."GeneralPopup_RecruitConfirm"..RecruitType.PrayerTen
|
||||||
local d = 0
|
local d = 0
|
||||||
if _args[3]==1 then
|
if _args[3]==1 then
|
||||||
d=RecruitManager.GetExpendDataByCostItem(wishSettingConfig.CostItemSingle)
|
d=RecruitManager.GetExpendDataByCostItem(wishSettingConfig.CostItemSingle,1,num)
|
||||||
elseif _args[3]==2 then
|
elseif _args[3]==2 then
|
||||||
d=RecruitManager.GetExpendDataByCostItem(wishSettingConfig.CostItemMul)
|
d=RecruitManager.GetExpendDataByCostItem(wishSettingConfig.CostItemMul,2,num)
|
||||||
end
|
end
|
||||||
|
|
||||||
if _args[3] == 1 then
|
if _args[3] == 1 then
|
||||||
|
|
|
@ -327,22 +327,35 @@ function this.GetExpendData(type)
|
||||||
return d
|
return d
|
||||||
end
|
end
|
||||||
|
|
||||||
function this.GetExpendDataByCostItem(str)
|
function this.GetExpendDataByCostItem(str,type,LimitNum)
|
||||||
local d
|
local d
|
||||||
local k=0
|
local k=0
|
||||||
for i, v in ipairs(str) do
|
local needNum= 0
|
||||||
if BagManager.GetItemCountById(v[1])>=v[2] then
|
if type==1 then
|
||||||
d=v
|
needNum=1
|
||||||
break
|
|
||||||
else
|
else
|
||||||
k=k+1
|
needNum=10
|
||||||
|
end
|
||||||
|
local cost=nil
|
||||||
|
for key, value in pairs(str) do
|
||||||
|
local bagNum=BagManager.GetItemCountById(value[1])
|
||||||
|
--不是妖晶 背包数量>=需要数量
|
||||||
|
if value[1]~=16 then
|
||||||
|
if bagNum>=needNum then
|
||||||
|
return value
|
||||||
|
else
|
||||||
|
cost=value
|
||||||
|
end
|
||||||
|
cost=value
|
||||||
|
|
||||||
|
else
|
||||||
|
--如果是妖晶 背包有足够妖晶 能抽的次数>=抽的次数
|
||||||
|
if bagNum>=needNum and LimitNum>=needNum then
|
||||||
|
return value
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
local l=#str
|
|
||||||
if k==l then
|
|
||||||
return str[l]
|
|
||||||
end
|
end
|
||||||
return d
|
return cost
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -156,6 +156,9 @@ function SingleRecruitPanel:BindEvent()
|
||||||
if state==1 then
|
if state==1 then
|
||||||
this.goBtn:SetActive(false)
|
this.goBtn:SetActive(false)
|
||||||
this.againBtn:SetActive(true)
|
this.againBtn:SetActive(true)
|
||||||
|
if recruitType and recruitType[1]==RecruitType.PrayerSingle then
|
||||||
|
this.againBtn:SetActive(false)
|
||||||
|
end
|
||||||
this.sureBtn:SetActive(true)
|
this.sureBtn:SetActive(true)
|
||||||
this.info:SetActive(false)
|
this.info:SetActive(false)
|
||||||
elseif state==2 then
|
elseif state==2 then
|
||||||
|
@ -399,7 +402,8 @@ function SingleRecruitPanel:UpdataPanelData(_heroData)
|
||||||
SetTextVerTial(self.posText.gameObject,Vector3.New(63.76,1.5,0),"MiddleLeft")
|
SetTextVerTial(self.posText.gameObject,Vector3.New(63.76,1.5,0),"MiddleLeft")
|
||||||
local d=nil
|
local d=nil
|
||||||
if recruitType and recruitType[1]==RecruitType.PrayerSingle then
|
if recruitType and recruitType[1]==RecruitType.PrayerSingle then
|
||||||
d=RecruitManager.GetExpendDataByCostItem(wishSettingConfig[1].CostItemSingle)
|
local num=PrivilegeManager.GetPrivilegeRemainValue(wishSettingConfig[1].DiamondMaxTimes)
|
||||||
|
d=RecruitManager.GetExpendDataByCostItem(wishSettingConfig[1].CostItemSingle,1,num)
|
||||||
else
|
else
|
||||||
d=RecruitManager.GetExpendData(type)
|
d=RecruitManager.GetExpendData(type)
|
||||||
end
|
end
|
||||||
|
@ -419,6 +423,9 @@ function SingleRecruitPanel:UpdataPanelData(_heroData)
|
||||||
this.goBtn:SetActive(heroStaticData.Star == 5 or heroStaticData.Star == 4)
|
this.goBtn:SetActive(heroStaticData.Star == 5 or heroStaticData.Star == 4)
|
||||||
this.sureBtn:SetActive(heroStaticData.Star ~= 5 and heroStaticData.Star ~= 4)
|
this.sureBtn:SetActive(heroStaticData.Star ~= 5 and heroStaticData.Star ~= 4)
|
||||||
this.againBtn:SetActive(heroStaticData.Star ~= 5 and heroStaticData.Star ~= 4)
|
this.againBtn:SetActive(heroStaticData.Star ~= 5 and heroStaticData.Star ~= 4)
|
||||||
|
if recruitType and recruitType[1]==RecruitType.PrayerSingle then
|
||||||
|
this.againBtn:SetActive(false)
|
||||||
|
end
|
||||||
Util.GetGameObject(self.transform, "rolePanel/rolePanel2"):SetActive(true)
|
Util.GetGameObject(self.transform, "rolePanel/rolePanel2"):SetActive(true)
|
||||||
if heroStaticData.Quality == 5 and heroStaticData.Natural >= 13 then
|
if heroStaticData.Quality == 5 and heroStaticData.Natural >= 13 then
|
||||||
HeroManager.DetectionOpenFiveStarActivity(heroStaticData.Star)
|
HeroManager.DetectionOpenFiveStarActivity(heroStaticData.Star)
|
||||||
|
|
|
@ -105,7 +105,7 @@ function TenRecruitPanel:OnOpen(...)
|
||||||
for i = 1, #_roleDatas do
|
for i = 1, #_roleDatas do
|
||||||
cardList[i]:OnOpen(_roleDatas[i].id,false,false,-1,self.sortingOrder)
|
cardList[i]:OnOpen(_roleDatas[i].id,false,false,-1,self.sortingOrder)
|
||||||
local heorConfig = ConfigManager.GetConfigData(ConfigName.HeroConfig,_roleDatas[i].heroId)
|
local heorConfig = ConfigManager.GetConfigData(ConfigName.HeroConfig,_roleDatas[i].heroId)
|
||||||
LogBlue("heorConfig.Star:"..heorConfig.Star)
|
-- LogBlue("heorConfig.Star:"..heorConfig.Star)
|
||||||
if heorConfig and heorConfig.Star >= 5 then
|
if heorConfig and heorConfig.Star >= 5 then
|
||||||
HeroManager.DetectionOpenFiveStarActivity(heorConfig.Star)
|
HeroManager.DetectionOpenFiveStarActivity(heorConfig.Star)
|
||||||
end
|
end
|
||||||
|
@ -114,7 +114,8 @@ function TenRecruitPanel:OnOpen(...)
|
||||||
local config=ConfigManager.TryGetConfigDataByKey(ConfigName.WishActivityUp,"ActivityId",type)
|
local config=ConfigManager.TryGetConfigDataByKey(ConfigName.WishActivityUp,"ActivityId",type)
|
||||||
if config then
|
if config then
|
||||||
local Setting= ConfigManager.GetConfigData(ConfigName.WishActivitySetting,1)
|
local Setting= ConfigManager.GetConfigData(ConfigName.WishActivitySetting,1)
|
||||||
d=RecruitManager.GetExpendDataByCostItem(Setting.CostItemMul)
|
local num=PrivilegeManager.GetPrivilegeRemainValue(Setting.DiamondMaxTimes)
|
||||||
|
d=RecruitManager.GetExpendDataByCostItem(Setting.CostItemMul,2,num)
|
||||||
else
|
else
|
||||||
d=RecruitManager.GetExpendData(type)
|
d=RecruitManager.GetExpendData(type)
|
||||||
end
|
end
|
||||||
|
|
|
@ -13,6 +13,7 @@ function TaSuiLingXiao:InitComponent()
|
||||||
self.btnBack = Util.GetGameObject(self.gameObject, "btnBack")
|
self.btnBack = Util.GetGameObject(self.gameObject, "btnBack")
|
||||||
self.btnHelp = Util.GetGameObject(self.gameObject, "btnHelp")
|
self.btnHelp = Util.GetGameObject(self.gameObject, "btnHelp")
|
||||||
self.btnRank = Util.GetGameObject(self.gameObject, "btnRank")
|
self.btnRank = Util.GetGameObject(self.gameObject, "btnRank")
|
||||||
|
self.btnRank:SetActive(false)
|
||||||
self.btnBox = Util.GetGameObject(self.gameObject, "progress/box")
|
self.btnBox = Util.GetGameObject(self.gameObject, "progress/box")
|
||||||
self.mid = Util.GetGameObject(self.gameObject, "mid")
|
self.mid = Util.GetGameObject(self.gameObject, "mid")
|
||||||
self.finishedText = Util.GetGameObject(self.mid, "FinishedText")
|
self.finishedText = Util.GetGameObject(self.mid, "FinishedText")
|
||||||
|
|
Loading…
Reference in New Issue