diff --git a/lua/app/ui/dungeon_armor/cell/chapter_cell.lua b/lua/app/ui/dungeon_armor/cell/chapter_cell.lua index 0a0f596c..03ce967a 100644 --- a/lua/app/ui/dungeon_armor/cell/chapter_cell.lua +++ b/lua/app/ui/dungeon_armor/cell/chapter_cell.lua @@ -3,17 +3,11 @@ local ChapterCell = class("ChapterCell", BaseCell) function ChapterCell:refresh(id) local uiMap = self:getUIMap() local index = self:getIndex() - local bg1 = uiMap["chapter_cell.bg_1"] - local bg2 = uiMap["chapter_cell.bg_2"] local touchNode = uiMap["chapter_cell.touch_node"] if index % 2 ~= 0 then -- 奇数 - bg1:setVisible(true) - bg2:setVisible(false) touchNode:setAnchoredPositionX(-125) else - bg1:setVisible(false) - bg2:setVisible(true) touchNode:setAnchoredPositionX(125) end @@ -43,12 +37,8 @@ function ChapterCell:refresh(id) local armorData = DataManager.DungeonData:getDungeonDataByType(ModuleManager.MODULE_KEY.DUNGEON_ARMOR) local config = armorData:getConfig(id) local starNum = armorData:getStarNum(id) - bgNode:setVisible(true) bgNode:setSprite(GConst.ATLAS_PATH.UI_DUGEON_ARMOR, config.stage_icon) spineNode:setVisible(false) - bgNode:setImageGray(false) - bottomBg:setImageGray(false) - chapterNode:setImageGray(false) if armorData:canFarmChapter(id) then -- 可扫荡 farmNode:setVisible(true) chapterNode:setAnchoredPositionY(43) @@ -70,14 +60,14 @@ function ChapterCell:refresh(id) else chapterNode:setAnchoredPositionY(8) starNode:setVisible(false) - bgNode:setVisible(false) spineNode:setVisible(true) spineObj:setVisible(false) + bgNode:setSprite(GConst.ATLAS_PATH.UI_DUGEON_ARMOR, "dungeon_armor_house_bg_2") local monsterId = config.monster[#config.monster] local monsterConfig = ConfigManager:getConfig("monster")[monsterId] local spineName = monsterConfig.model_id spineObj:loadAssetAsync(spineName, function() - spineObj:setVisible(true, 0.75) + spineObj:setVisible(true, 0.65) spineObj:playAnim("idle", true, false, true) end, true) end @@ -89,13 +79,11 @@ function ChapterCell:refresh(id) chapterNode:setAnchoredPositionY(8) starNode:setVisible(false) - bgNode:setImageGray(true) - bottomBg:setImageGray(true) - chapterNode:setImageGray(true) - touchNode:addClickListener(function() GFunc.showToast(I18N:getGlobalText(I18N.GlobalConst.PASS_REQUIRE)) end) + + bgNode:setSprite(GConst.ATLAS_PATH.UI_DUGEON_ARMOR, config.stage_icon .. "_1") end end