Merge branch 'TCX_LongZhu' of http://192.168.1.21:3000/root/miduo_client into TCX_LongZhu

TCX_LongZhu
PC-202302260912\Administrator 2026-05-09 15:52:59 +08:00
commit 0efef0bbff
2 changed files with 1829 additions and 730 deletions

View File

@ -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 ()
--未解锁的不可查看