Update - 1.5.0.80

EN: 1.5.0.80
CN: 1.5.0.82
JP: 1.5.0.84
KR: 1.5.0.87
This commit is contained in:
SL1900
2026-01-20 18:00:00 +09:00
parent 235fee6915
commit 999664ac13
127 changed files with 484147 additions and 211 deletions
@@ -24,6 +24,7 @@ SettingsResolutionCtrl._mapNodeConfig = {
sComponentName = "TMP_Text",
sLanguageId = "MessageBox_Cancel"
},
List = {},
txtOptionTitle = {nCount = 4, sComponentName = "TMP_Text"},
btnChoose = {
nCount = 4,
@@ -32,16 +33,26 @@ SettingsResolutionCtrl._mapNodeConfig = {
},
Checkmark = {nCount = 4, sComponentName = "Animator"},
Option = {nCount = 4},
line = {nCount = 4}
line = {nCount = 4},
sv = {},
OptionGrid = {},
Content = {sComponentName = "Transform"}
}
SettingsResolutionCtrl._mapEventConfig = {}
function SettingsResolutionCtrl:Open(nResolution, tbResolution)
self.nIndex = nResolution
self.tbResolution = tbResolution
self:PlayInAni()
self:Refresh()
local nCount = #self.tbResolution
self._mapNode.sv:SetActive(4 < nCount)
self._mapNode.List:SetActive(nCount <= 4)
if 4 < nCount then
self:RefreshSv()
else
self:RefreshList()
end
end
function SettingsResolutionCtrl:Refresh()
function SettingsResolutionCtrl:RefreshList()
local nCount = #self.tbResolution
if 4 <= nCount then
self._mapNode.line[4]:SetActive(false)
@@ -65,6 +76,27 @@ function SettingsResolutionCtrl:Refresh()
end
end
end
function SettingsResolutionCtrl:RefreshSv()
self.tbCheckmark = {}
delChildren(self._mapNode.Content)
for i, sText in ipairs(self.tbResolution) do
local goOption = instantiate(self._mapNode.OptionGrid, self._mapNode.Content)
goOption:SetActive(true)
local txtOptionTitle = goOption.transform:Find("txtOptionTitle"):GetComponent("TMP_Text")
NovaAPI.SetTMPText(txtOptionTitle, sText)
local Checkmark = goOption.transform:Find("btnChoose/Background/Checkmark"):GetComponent("Animator")
self.tbCheckmark[i] = Checkmark
if i == self.nIndex then
Checkmark:Play("checkmark_in", -1, 1)
else
Checkmark:Play("checkmark_out", -1, 1)
end
local btnChoose = goOption.transform:Find("btnChoose")
local btn = btnChoose:GetComponent("UIButton")
local func_Handler = ui_handler(self, self.OnBtnClick_ChooseGrid, btnChoose.gameObject, i)
btn.onClick:AddListener(func_Handler)
end
end
function SettingsResolutionCtrl:PlayInAni()
self.gameObject:SetActive(true)
self.ani:Play("t_window_04_t_in")
@@ -101,4 +133,12 @@ function SettingsResolutionCtrl:OnBtnClick_Choose(btn, index)
self._mapNode.Checkmark[index]:SetTrigger("PlayCheckmarkShow")
self.nIndex = index
end
function SettingsResolutionCtrl:OnBtnClick_ChooseGrid(btn, index)
if self.nIndex == index then
return
end
self.tbCheckmark[self.nIndex]:SetTrigger("PlayCheckmarkHide")
self.tbCheckmark[index]:SetTrigger("PlayCheckmarkShow")
self.nIndex = index
end
return SettingsResolutionCtrl