Merge branch 'china/dev' of http://60.1.1.230/gaoxin/JL_Client into china/dev

dev_chengFeng
jiaoyangna 2021-09-18 17:07:42 +08:00
commit 02f1888f3f
4 changed files with 20 additions and 5 deletions

View File

@ -221,6 +221,7 @@ function this.GetBaoKuData()
if v.missionId == 100 then
actData.curLevel = v.progress
curBasicPool = tonumber(BasicPoolId[v.progress])
actData.poolId = curBasicPool
curFinalPool = BlessingConfigNew.FinalPoolId
elseif v.missionId > 1000 then
local data = {}
@ -271,7 +272,7 @@ end
function this.GetLeftRewardData()
local actData = this.GetBaoKuData()
local finalCardDatas = actData.finalCardDatas
local RewardConfig = ConfigManager.GetAllConfigsDataByKey(ConfigName.BlessingRewardPoolNew,"PoolId",actData.curLevel)--初始所有奖励数据
local RewardConfig = ConfigManager.GetAllConfigsDataByKey(ConfigName.BlessingRewardPoolNew,"PoolId",actData.poolId)--初始所有奖励数据
local data={}
for i = 1, #RewardConfig do
data[RewardConfig[i].Id] = {}

View File

@ -63,6 +63,12 @@ function this:OnShow(_parent,...)
this.titleText.text = Language[10760]
curId = ActData.selectId or nil
local RewardConfig = ConfigManager.GetAllConfigsDataByKey(ConfigName.BlessingRewardPoolNew,"PoolId",ActData.curFinalPool)
table.sort(RewardConfig, function(a, b)
if a.FloorLimit == b.FloorLimit then
return a.Id < b.Id
end
return a.FloorLimit < b.FloorLimit
end)
this.ScrollView:SetData(RewardConfig, function(index, go)
this:SetSingleData(index,go, RewardConfig[index])
end)
@ -131,10 +137,12 @@ function this:SetSingleData(index,item,data)
t2 = false
end
-- LogRed(ActData.allData[index].rewardId..""..tostring(ActData.allData[index].progress))
if ActData.allData[index].progress > data.InitializeNum then
t3 = false
elseif ActData.allData[index].progress == data.InitializeNum and ActData.curLevel > data.InitializeNum then
if ActData.allData[index].progress >= data.InitializeNum then
t3 = false
-- 如果是当前层选中的特殊奖励
if ActData.allData[index].progress == data.InitializeNum and ActData.selectId == data.Id then--and ActData.curLevel > data.InitializeNum
t3 = true
end
num.text = "<color=red>"..(data.InitializeNum-ActData.allData[index].progress).."/"..data.InitializeNum.."</color>"
else
t3 = true

View File

@ -81,7 +81,7 @@ function this:OnShow(_parent,...)
table.insert(tempData,value)
end
this.ScrollView:SetData(tempData, function(index, go)
this:SetSingleData(index,go,leftRewardData[index + (ActData.curLevel-1)*10])
this:SetSingleData(index,go,leftRewardData[index + (ActData.poolId-1)*10])
end)
end

View File

@ -69,10 +69,16 @@ end
--添加事件监听(用于子类重写)
function XunBaoMiZong:AddListener()
Game.GlobalEvent:AddEvent(GameEvent.Bag.BagGold, self.UpdateGoldVal, self)
end
--移除事件监听(用于子类重写)
function XunBaoMiZong:RemoveListener()
Game.GlobalEvent:RemoveEvent(GameEvent.Bag.BagGold, self.UpdateGoldVal, self)
end
function XunBaoMiZong:UpdateGoldVal()
self:Refresh()
end
function XunBaoMiZong:OnSortingOrderChange(_sortingOrder)