【家园】摘星阁提交
parent
90ffb03c25
commit
0bed9188dc
|
@ -129,11 +129,11 @@ function this:SetData()
|
||||||
--设置消耗
|
--设置消耗
|
||||||
local limit = EquipStrengthen[HomeLandManager.EquipData[curIndex].Id].Limit
|
local limit = EquipStrengthen[HomeLandManager.EquipData[curIndex].Id].Limit
|
||||||
local cost = EquipStrengthen[HomeLandManager.EquipData[curIndex].Id].Cost
|
local cost = EquipStrengthen[HomeLandManager.EquipData[curIndex].Id].Cost
|
||||||
|
this.costIcon.sprite = this.spLoader:LoadSprite(GetSpriteNameByItemId(cost[1][1]))
|
||||||
if HomeLandManager.BuildData[limit[1]].level >= limit[2] then
|
if HomeLandManager.BuildData[limit[1]].level >= limit[2] then
|
||||||
this.costCondition.text = ""
|
this.costCondition.text = ""
|
||||||
this.costIcon.gameObject:SetActive(true)
|
this.costIcon.gameObject:SetActive(true)
|
||||||
this.costNum.gameObject:SetActive(true)
|
this.costNum.gameObject:SetActive(true)
|
||||||
this.costIcon.sprite = this.spLoader:LoadSprite(GetSpriteNameByItemId(cost[1][1]))
|
|
||||||
local color2 = BagManager.GetTotalItemNum(cost[1][1]) >= cost[1][2] and "#FFEED6" or "red"
|
local color2 = BagManager.GetTotalItemNum(cost[1][1]) >= cost[1][2] and "#FFEED6" or "red"
|
||||||
this.costNum.text = string.format("<color=%s>%s</color>",color2,cost[1][2])
|
this.costNum.text = string.format("<color=%s>%s</color>",color2,cost[1][2])
|
||||||
else
|
else
|
||||||
|
@ -155,6 +155,8 @@ function this:SetData()
|
||||||
if not bool and HomeLandManager.GetAllCanUpgrade() then
|
if not bool and HomeLandManager.GetAllCanUpgrade() then
|
||||||
this.Cost:SetActive(true)
|
this.Cost:SetActive(true)
|
||||||
this.Tips:SetActive(false)
|
this.Tips:SetActive(false)
|
||||||
|
this.costIcon.gameObject:SetActive(true)
|
||||||
|
this.costNum.gameObject:SetActive(true)
|
||||||
this.costCondition.gameObject:SetActive(false)
|
this.costCondition.gameObject:SetActive(false)
|
||||||
--突破的消耗和升级不同
|
--突破的消耗和升级不同
|
||||||
local cost = EquipRankUp[HomeLandManager.levelProId].Cost
|
local cost = EquipRankUp[HomeLandManager.levelProId].Cost
|
||||||
|
|
Loading…
Reference in New Issue