Commit 4d684a8b7e1cd17fbf53a64ac8889d698f719c00

Authored by zhangqijia
1 parent fe562215

fix: 宝藏图鉴-优化 检查拾荒关卡是否通关

Showing 1 changed file with 2 additions and 14 deletions   Show diff stats
src/models/Daily.lua
... ... @@ -100,21 +100,9 @@ function Daily:checkUnlock(treaval)
100 100 local treasureC = treaval.unlock:toArray(true, "=")
101 101 local show = false
102 102 if treasureC[1] == 1 then --通关关卡
103   - if self.owner:checkHangPass(treasureC[2]) then show = true end
  103 + show = self.owner:checkHangPass(treasureC[2])
104 104 elseif treasureC[1] == 2 then --通关拾荒章节=x层
105   - local chapterId = treasureC[2]
106   - local layer = 1
107   - local advCsv = csvdb["adv_chapterCsv"][chapterId]
108   - if not advCsv then return false end --不存在的章节
109   - if math.floor(chapterId / 100) ~= 2 then
110   - layer = math.min(layer, advCsv.limitlevel)
111   - end
112   - local advPass = role:getProperty("advPass")
113   - if (advPass[chapterId] or 0) < layer then
114   - show = false
115   - else
116   - show = true
117   - end
  105 + show = role:checkAdvChapterPass(treasureC[2])
118 106 elseif treasureC[1] == 3 then --拥有指定id的角色时
119 107 local hero = role:getHeroByID(treasureC[2])
120 108 if hero then show = true end
... ...