This commit is contained in:
puxuan 2025-08-21 16:22:38 +08:00
parent c5bb9e07fe
commit a4b72a6aaa
3 changed files with 10 additions and 2 deletions

View File

@ -673,6 +673,7 @@ local LocalizationGlobalConst =
HERO_DESC_20 = "HERO_DESC_20",
SUMMON_DESC_3 = "SUMMON_DESC_3",
SUMMON_DESC_4 = "SUMMON_DESC_4",
IDLE_DESC_2 = "IDLE_DESC_2",
}
return LocalizationGlobalConst

View File

@ -673,6 +673,7 @@ local localization_global =
["HERO_DESC_20"] = "可继续升级",
["SUMMON_DESC_3"] = "在[高级招聘]中,如果连续49次没有获得传说快递员,则第50次必 当获得传说快递员;且在[高级招聘]中获得任意传说快递员时,该",
["SUMMON_DESC_4"] = "概率预览",
["IDLE_DESC_2"] = "游历时间:<color=#00F6FF>{0}</color>",
}
return localization_global

View File

@ -78,6 +78,8 @@ function IdleDropUI:onLoadRootComplete()
self.adBtn = uiMap["idle_drop_ui.bg.ad_btn"]
self.adBtnImg = uiMap["idle_drop_ui.bg.ad_btn.img"]
self.adTimesTx = uiMap["idle_drop_ui.bg.ad_times_tx"]
self.quickTimesTx = uiMap["idle_drop_ui.bg.quick_times_tx"]
self.adBtn:addClickListener(function()
ModuleManager.IdleManager:getIdleQuickRewrad(true)
end)
@ -256,6 +258,7 @@ function IdleDropUI:refreshBtns()
self.getBtn:setTouchEnable(false)
end
local quickTimes = DataManager.IdleData:getQuickIdleVitRemainTimes()
self.quickTimesTx:setText(I18N:getGlobalText(I18N.GlobalConst.TODAY_REMAIN_TIMES, "<color=#60FF4B>" .. quickTimes .."</color>"))
if quickTimes > 0 then
self.quickBtn:setSprite(GConst.ATLAS_PATH.COMMON, "common_btn_blue_1")
self.quickBtn:setTouchEnable(true)
@ -267,6 +270,7 @@ function IdleDropUI:refreshBtns()
end
local adRemainTimes = DataManager.IdleData:getQuickIdleAdRemainTimes()
self.adTimesTx:setText(I18N:getGlobalText(I18N.GlobalConst.TODAY_REMAIN_TIMES, "<color=#60FF4B>" .. adRemainTimes .."</color>"))
if adRemainTimes <= 0 then
adRemainTimes = 0
self.adBtn:setTouchEnable(false)
@ -288,10 +292,12 @@ function IdleDropUI:refreshCD()
else
self:removeGetBtnRedPoint()
end
self.timeTx:setText(Time:formatNumTime(idleMaxTime))
local str = I18N:getGlobalText(I18N.GlobalConst.IDLE_DESC_2, Time:formatNumTime(idleMaxTime))
self.timeTx:setText(str)
else
self:removeGetBtnRedPoint()
self.timeTx:setText(Time:formatNumTime(time))
local str = I18N:getGlobalText(I18N.GlobalConst.IDLE_DESC_2, Time:formatNumTime(time))
self.timeTx:setText(str)
end
if self.lastRefreshTime == nil then
self.lastRefreshTime = Time:getServerTime()