Merge branch 'china/dev' into china/test
commit
a371c2d7ff
|
|
@ -472,6 +472,7 @@ GameEvent = {
|
||||||
RechargeQinglongSerectSuccess = "EndLess.RechargeQinglongSerectSuccess",
|
RechargeQinglongSerectSuccess = "EndLess.RechargeQinglongSerectSuccess",
|
||||||
RefreshHeroData = "EndLess.RefreshHeroData",
|
RefreshHeroData = "EndLess.RefreshHeroData",
|
||||||
GuidePanel = "EndLess.GuidePanel",
|
GuidePanel = "EndLess.GuidePanel",
|
||||||
|
QinglongSerectRefresh = "EndLess.QinglongSerectRefresh",
|
||||||
},
|
},
|
||||||
--山河社稷图
|
--山河社稷图
|
||||||
FightLevel={
|
FightLevel={
|
||||||
|
|
|
||||||
|
|
@ -1375,7 +1375,8 @@ function this.CheckRedpointUpperMonthCard(red)
|
||||||
if not actInfo then
|
if not actInfo then
|
||||||
return false
|
return false
|
||||||
end
|
end
|
||||||
if actInfo.value ~= 1 then
|
LogGreen("actInfo.value:"..actInfo.value)
|
||||||
|
if actInfo.value ~= 2 then
|
||||||
return false
|
return false
|
||||||
end
|
end
|
||||||
for i = 1,#actInfo.mission do
|
for i = 1,#actInfo.mission do
|
||||||
|
|
|
||||||
|
|
@ -227,8 +227,7 @@ function EndLessMapView:BindEvent()
|
||||||
return
|
return
|
||||||
end
|
end
|
||||||
if not this:CanClick() then return end
|
if not this:CanClick() then return end
|
||||||
local data = EndLessMapManager.treasureData
|
UIManager.OpenPanel(UIName.EndLessTreasurePanel)
|
||||||
UIManager.OpenPanel(UIName.EndLessTreasurePanel,data)
|
|
||||||
end)
|
end)
|
||||||
|
|
||||||
Util.AddClick(this.btnFormat, function ()
|
Util.AddClick(this.btnFormat, function ()
|
||||||
|
|
|
||||||
|
|
@ -145,7 +145,10 @@ function this.EenlessTreasureRefreshIndication(buffer)
|
||||||
local data = buffer:DataByte()
|
local data = buffer:DataByte()
|
||||||
local msg = MapInfoProto_pb.EndlessTreasureInfoResponse()
|
local msg = MapInfoProto_pb.EndlessTreasureInfoResponse()
|
||||||
msg:ParseFromString(data)
|
msg:ParseFromString(data)
|
||||||
|
local num = BagManager.GetItemCountById(EndLessMapManager.scoreValueId)
|
||||||
|
BagManager.HeroLvUpUpdateItemsNum(EndLessMapManager.scoreValueId, num)
|
||||||
EndLessMapManager.InitTreasureData(msg)
|
EndLessMapManager.InitTreasureData(msg)
|
||||||
|
Game.GlobalEvent:DispatchEvent(GameEvent.EndLess.QinglongSerectRefresh)
|
||||||
end
|
end
|
||||||
|
|
||||||
--后端推送福利红包数据
|
--后端推送福利红包数据
|
||||||
|
|
|
||||||
|
|
@ -226,7 +226,7 @@ function CommonActPage:RefreshTime()
|
||||||
local freshTime
|
local freshTime
|
||||||
if self.actType == ActivityTypeDef.AccumulativeRechargeExper then
|
if self.actType == ActivityTypeDef.AccumulativeRechargeExper then
|
||||||
freshTime = CalculateSecondsNowTo_N_OClock(24)
|
freshTime = CalculateSecondsNowTo_N_OClock(24)
|
||||||
elseif self.actConfig.ActiveType == ActivityTypeDef.DynamicAct then
|
elseif self.actConfig.ActiveType == ActivityTypeDef.DynamicAct and self.actConfig.Sort == 2 then
|
||||||
if (self.ActData.endTime - GetTimeStamp()) <= 86280 then
|
if (self.ActData.endTime - GetTimeStamp()) <= 86280 then
|
||||||
freshTime = CalculateSecondsNowTo_N_OClock(24) - 120
|
freshTime = CalculateSecondsNowTo_N_OClock(24) - 120
|
||||||
else
|
else
|
||||||
|
|
|
||||||
|
|
@ -224,7 +224,7 @@ end
|
||||||
function this.InitTaskData(curData,taskType,configName)
|
function this.InitTaskData(curData,taskType,configName)
|
||||||
local allListData = ConfigManager.GetAllConfigsDataByKey(configName, "ActivityId", curData.activityId)
|
local allListData = ConfigManager.GetAllConfigsDataByKey(configName, "ActivityId", curData.activityId)
|
||||||
local allMissionData = TaskManager.GetTypeTaskList(taskType)
|
local allMissionData = TaskManager.GetTypeTaskList(taskType)
|
||||||
-- LogGreen("this.DynamicActType:"..this.DynamicActType)
|
Log("this.DynamicActType:"..this.DynamicActType)
|
||||||
for i=1,#allListData do
|
for i=1,#allListData do
|
||||||
for j=1,#allMissionData do
|
for j=1,#allMissionData do
|
||||||
-- LogGreen("this.DynamicActType:"..this.DynamicActType)
|
-- LogGreen("this.DynamicActType:"..this.DynamicActType)
|
||||||
|
|
|
||||||
|
|
@ -44,21 +44,23 @@ end
|
||||||
--添加事件监听(用于子类重写)
|
--添加事件监听(用于子类重写)
|
||||||
function EndLessTreasurePanel:AddListener()
|
function EndLessTreasurePanel:AddListener()
|
||||||
Game.GlobalEvent:AddEvent(GameEvent.EndLess.RechargeQinglongSerectSuccess, self.refresh,self)
|
Game.GlobalEvent:AddEvent(GameEvent.EndLess.RechargeQinglongSerectSuccess, self.refresh,self)
|
||||||
|
Game.GlobalEvent:AddEvent(GameEvent.EndLess.QinglongSerectRefresh, self.OnShow,self)
|
||||||
end
|
end
|
||||||
|
|
||||||
--移除事件监听(用于子类重写)
|
--移除事件监听(用于子类重写)
|
||||||
function EndLessTreasurePanel:RemoveListener()
|
function EndLessTreasurePanel:RemoveListener()
|
||||||
Game.GlobalEvent:RemoveEvent(GameEvent.EndLess.RechargeQinglongSerectSuccess, self.refresh,self)
|
Game.GlobalEvent:RemoveEvent(GameEvent.EndLess.RechargeQinglongSerectSuccess, self.refresh,self)
|
||||||
|
Game.GlobalEvent:AddEvent(GameEvent.EndLess.QinglongSerectRefresh, self.OnShow,self)
|
||||||
end
|
end
|
||||||
|
|
||||||
--界面打开时调用(用于子类重写)
|
--界面打开时调用(用于子类重写)
|
||||||
function EndLessTreasurePanel:OnOpen(...)
|
function EndLessTreasurePanel:OnOpen(...)
|
||||||
local args = {...}
|
|
||||||
self.treasureData = args[1]
|
|
||||||
end
|
end
|
||||||
|
|
||||||
-- 打开,重新打开时回调
|
-- 打开,重新打开时回调
|
||||||
function EndLessTreasurePanel:OnShow()
|
function EndLessTreasurePanel:OnShow()
|
||||||
|
self.treasureData = EndLessMapManager.treasureData
|
||||||
self.tips.text = self.treasureData.tip
|
self.tips.text = self.treasureData.tip
|
||||||
--self.time.gameObject:SetActive(false)
|
--self.time.gameObject:SetActive(false)
|
||||||
self.time.text = "重置时间:"..TimeToDHMS(self.treasureData.resetTime - GetTimeStamp())
|
self.time.text = "重置时间:"..TimeToDHMS(self.treasureData.resetTime - GetTimeStamp())
|
||||||
|
|
@ -243,8 +245,10 @@ function EndLessTreasurePanel:ShowTime()
|
||||||
self.localTimer = Timer.New(function()
|
self.localTimer = Timer.New(function()
|
||||||
time = time - 1
|
time = time - 1
|
||||||
if time <= 0 then
|
if time <= 0 then
|
||||||
self.treasureState = 0
|
self.time.text = "重置时间:"..TimeToDHMS(0)
|
||||||
self.ScrollView:SetIndex(1)
|
self.localTimer:Stop()
|
||||||
|
self.localTimer = nil
|
||||||
|
return
|
||||||
end
|
end
|
||||||
self.time.text = "重置时间:"..TimeToDHMS(time)
|
self.time.text = "重置时间:"..TimeToDHMS(time)
|
||||||
end,1,-1,true)
|
end,1,-1,true)
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,6 @@
|
||||||
|
|
||||||
local _ShopTypeConfig = ConfigManager.GetConfig(ConfigName.StoreTypeConfig)
|
local _ShopTypeConfig = ConfigManager.GetConfig(ConfigName.StoreTypeConfig)
|
||||||
|
local GlobalActConfig = ConfigManager.GetConfig(ConfigName.GlobalActivity)
|
||||||
-- 通用得商店逻辑
|
-- 通用得商店逻辑
|
||||||
local ShopViewNew = {}
|
local ShopViewNew = {}
|
||||||
local sortingOrder = 0
|
local sortingOrder = 0
|
||||||
|
|
@ -148,15 +149,19 @@ function ShopViewNew:OnShow(_sortingOrder)
|
||||||
LogGreen("id:"..id)
|
LogGreen("id:"..id)
|
||||||
if id and id > 0 then
|
if id and id > 0 then
|
||||||
self.actId = id
|
self.actId = id
|
||||||
local config = ConfigManager.TryGetConfigDataByThreeKey(ConfigName.ActivityGroups,"PageType",self.actConfig.PageType,"ActiveType",self.actConfig.ActiveType,"ActId",id)
|
local actConfig
|
||||||
if config then
|
local actConfig = ConfigManager.TryGetConfigDataByThreeKey(ConfigName.ActivityGroups,"ActId",GlobalActConfig[id].ShowArt,"PageType",self.actConfig.PageType,"ActiveType",self.actConfig.ActiveType)
|
||||||
self.actConfig = config
|
if not actConfig then
|
||||||
|
actConfig = ConfigManager.TryGetConfigDataByThreeKey(ConfigName.ActivityGroups,"ActId",id,"PageType",self.actConfig.PageType,"ActiveType",self.actConfig.ActiveType)
|
||||||
|
end
|
||||||
|
if actConfig then
|
||||||
|
self.actConfig = actConfig
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
self.ShopType = self.actConfig.ShopData[1][1]
|
self.ShopType = self.actConfig.ShopData[1][1]
|
||||||
-- LogYellow("self.ShopType:"..tostring(self.ShopType))
|
LogYellow("self.ShopType:"..tostring(self.ShopType))
|
||||||
if self.ShopType == SHOP_TYPE.QIANKUNBOX_SHOP then
|
if self.ShopType == SHOP_TYPE.QIANKUNBOX_SHOP then
|
||||||
self.parent.tabbox.gameObject:SetActive(false)
|
self.parent.tabbox.gameObject:SetActive(false)
|
||||||
else
|
else
|
||||||
|
|
@ -172,6 +177,7 @@ function ShopViewNew:ShowShop()
|
||||||
end)
|
end)
|
||||||
-- 红点销毁
|
-- 红点销毁
|
||||||
self.refreshRedpot:SetActive(false)
|
self.refreshRedpot:SetActive(false)
|
||||||
|
LogYellow("self.ShopType:"..tostring(self.ShopType))
|
||||||
self.ShopId = ShopManager.GetShopDataByType(self.ShopType).id
|
self.ShopId = ShopManager.GetShopDataByType(self.ShopType).id
|
||||||
self.ShopConfig = _ShopTypeConfig[self.ShopId]
|
self.ShopConfig = _ShopTypeConfig[self.ShopId]
|
||||||
-- 显示帮助按钮
|
-- 显示帮助按钮
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue