From 1501b7f4f039cdec8aa31d36b2aa61c6080916f4 Mon Sep 17 00:00:00 2001 From: "DESKTOP-MMO982B\\User" <752966621@qq.com> Date: Sat, 9 May 2026 15:28:12 +0800 Subject: [PATCH] 1 --- .../Modules/Practice/PracticeImprintPanel.lua | 35 +++++++++++++++++++ 1 file changed, 35 insertions(+) diff --git a/Assets/ManagedResources/~Lua/Modules/Practice/PracticeImprintPanel.lua b/Assets/ManagedResources/~Lua/Modules/Practice/PracticeImprintPanel.lua index 3ece112ce9..f1e41d5599 100644 --- a/Assets/ManagedResources/~Lua/Modules/Practice/PracticeImprintPanel.lua +++ b/Assets/ManagedResources/~Lua/Modules/Practice/PracticeImprintPanel.lua @@ -122,6 +122,9 @@ function PracticeImprint:SetSingleImprint(_go,_data) local name = Util.GetGameObject(_go, "name/Text"):GetComponent("Text") local selectImg = Util.GetGameObject(_go, "select") local redPoint = Util.GetGameObject(_go, "redPoint") + local suoBG = Util.GetGameObject(_go.transform.parent.parent, "suoBG") + local suoBGText = Util.GetGameObject(_go.transform.parent.parent, "suoBG/title"):GetComponent("Text") + suoBGText.text = "" selectImg:SetActive(false) redPoint:SetActive(false) self.SelectList[_imprintId] = selectImg @@ -132,6 +135,12 @@ function PracticeImprint:SetSingleImprint(_go,_data) maskBlack:SetActive(true) Util.SetGray(icon.gameObject,true) Util.SetGray(kuang,true) + for i = 1, #configData.OpenSkillSet do + local data = configData.OpenSkillSet[i] + local itemConfig = ConfigManager.GetConfigDataByKey(ConfigName.ItemConfig,"Id",configData.OpenSkillSet[i][1]) + suoBGText.text = "收集"..itemConfig.Name..data[2].."个后开启\n" + end + else--已解锁 maskBlack:SetActive(false) if PlayerPrefs.GetInt(PlayerManager.uid.."Imprint"..configData.Id) == 0 then @@ -153,6 +162,32 @@ function PracticeImprint:SetSingleImprint(_go,_data) end icon.sprite = self.spLoader:LoadSprite(GetResourcePath(configData.Icon)) name.text = configData.Name + local heroContion = Util.GetGameObject(_go,"needsList") + if configData.OpenType == 1 then + heroContion:SetActive(true) + for i=1, #configData.OpenValue do + local t = Util.GetGameObject(_go,"needsList/pre"..tostring(i).."/head"):GetComponent("Image") + local condition = Util.GetGameObject(_go,"needsList/pre"..tostring(i).."/Text"):GetComponent("Text") + local heroConfig = ConfigManager.GetConfigDataByKey(ConfigName.HeroConfig,"Id",configData.OpenValue[i][1]) + t.sprite=self.spLoader:LoadSprite(GetResourcePath(heroConfig.Icon)) + if configData.OpenValue[i][2] > 10 then + condition.text = "飞升" .. (configData.OpenValue[i][2]-10) + else + condition.text = configData.OpenValue[i][2] .."星" + end + end + elseif configData.OpenType == 2 then + heroContion:SetActive(true) + for i=1, #configData.OpenValue do + local t = Util.GetGameObject(_go,"needsList/pre"..tostring(i).."/head"):GetComponent("Image") + local condition = Util.GetGameObject(_go,"needsList/pre"..tostring(i).."/Text"):GetComponent("Text") + local itemConfig = ConfigManager.GetConfigDataByKey(ConfigName.ItemConfig,"Id",configData.OpenValue[i][1]) + t.sprite=self.spLoader:LoadSprite(GetResourcePath(itemConfig.ResourceID)) + condition.text = configData.OpenValue[i][2].."级" + end + else + heroContion:SetActive(false) + end Util.AddOnceClick(maskBtn,function () --未解锁的不可查看