显示bug修复
This commit is contained in:
parent
cc9f3a9137
commit
b20644f4cb
@ -211,8 +211,8 @@ function BattleRuneResultUI:refreshTaskNode()
|
||||
local condition = chapterCondition[newIndex]
|
||||
if condition then
|
||||
objs.cell:getBaseObject():setActive(true)
|
||||
local taskNum = taskProgress[index] and taskProgress[index].progress
|
||||
local desc = self.runeData:getConditionDesc(condition, taskNum)
|
||||
local taskNum = taskProgress[newIndex] and taskProgress[newIndex].progress
|
||||
local desc = self.runeData:getConditionDesc(condition)
|
||||
local over = false
|
||||
if taskProgress[newIndex] then
|
||||
local info = taskProgress[newIndex]
|
||||
|
||||
@ -510,14 +510,15 @@ function BattleUI:refreshTaskNode()
|
||||
|
||||
local atlast, iconName = runeData:getConditionIcon(condition)
|
||||
local taskNum = condition[3] or 0
|
||||
Logger.printTable(taskProgress)
|
||||
local over = false
|
||||
if taskProgress[newIndex] then
|
||||
taskNum = taskProgress[newIndex].totalProgress - taskProgress[newIndex].progress
|
||||
if taskNum < 0 then
|
||||
taskNum = 0
|
||||
end
|
||||
over = taskProgress[newIndex].over
|
||||
end
|
||||
cell:refresh(atlast, iconName, taskNum)
|
||||
cell:refresh(atlast, iconName, taskNum, over)
|
||||
cell:addClickListener(function()
|
||||
ModuleManager.DungeonRuneManager:showTaskUI(self.battleController.chapterId)
|
||||
end)
|
||||
|
||||
@ -2,18 +2,17 @@ local BattleTaskCell = class("BattleTaskCell", BaseCell)
|
||||
|
||||
local BG = {"common_board_131", "common_board_132"} -- 紫绿
|
||||
|
||||
function BattleTaskCell:refresh(iconAtlas, iconName, taskNum)
|
||||
function BattleTaskCell:refresh(iconAtlas, iconName, taskNum, over)
|
||||
local uiMap = self:getUIMap()
|
||||
local bg = uiMap["battle_task_cell.bg"]
|
||||
local icon = uiMap["battle_task_cell.icon"]
|
||||
local point = uiMap["battle_task_cell.point"]
|
||||
local desc = uiMap["battle_task_cell.desc"]
|
||||
local check = uiMap["battle_task_cell.check"]
|
||||
icon:setSprite(iconAtlas, iconName)
|
||||
|
||||
check:setVisible(over == true)
|
||||
desc:setText(taskNum)
|
||||
self:hidePoint(not taskNum)
|
||||
|
||||
self:hidePoint(false)
|
||||
end
|
||||
|
||||
function BattleTaskCell:hidePoint(hide)
|
||||
|
||||
@ -38,7 +38,7 @@ function DungeonRuneTaskUI:_display()
|
||||
local condition = chapterCondition[newIndex]
|
||||
if condition then
|
||||
cell:getBaseObject():setActive(true)
|
||||
local taskNum = taskProgress[index] and taskProgress[index].progress
|
||||
local taskNum = taskProgress[newIndex] and taskProgress[newIndex].progress
|
||||
local desc = self.runeData:getConditionDesc(condition, taskNum)
|
||||
local over = false
|
||||
if taskProgress[newIndex] then
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user