Update - 1.13.0.124
EN: 1.13.0.124 CN: 1.13.0.124 JP: 1.13.0.128 KR: 1.13.0.130
This commit is contained in:
@@ -0,0 +1,32 @@
|
||||
local iconPath2 = "Icon/SoldierOtherIcon/"
|
||||
local SoldierEffectDesCtrl = class("SoldierEffectDesCtrl", BaseCtrl)
|
||||
SoldierEffectDesCtrl._mapNodeConfig = {
|
||||
txtTitle = {
|
||||
sComponentName = "TMP_Text",
|
||||
sLanguageId = "Soldier_Sandtable_PositionEffect"
|
||||
},
|
||||
ImageIcon = {sComponentName = "Image"},
|
||||
TextDes = {sComponentName = "TMP_Text"},
|
||||
btnClose = {
|
||||
sComponentName = "UIButton",
|
||||
callback = "OnBtnClick_Close"
|
||||
}
|
||||
}
|
||||
SoldierEffectDesCtrl._mapEventConfig = {}
|
||||
SoldierEffectDesCtrl._mapRedDotConfig = {}
|
||||
function SoldierEffectDesCtrl:HideTips()
|
||||
self.gameObject:SetActive(false)
|
||||
end
|
||||
function SoldierEffectDesCtrl:ShowTips(nPositionIndex)
|
||||
self.gameObject:SetActive(true)
|
||||
local nCfgId = PlayerData.SoldierData:GetSoldierPositionEffectDataId(nPositionIndex)
|
||||
local cfg = ConfigTable.GetData("SoldierPositionEffect", nCfgId)
|
||||
if cfg then
|
||||
self:SetPngSprite(self._mapNode.ImageIcon, iconPath2 .. cfg.Icon)
|
||||
NovaAPI.SetTMPText(self._mapNode.TextDes, cfg.KeyEffectDes)
|
||||
end
|
||||
end
|
||||
function SoldierEffectDesCtrl:OnBtnClick_Close()
|
||||
self:HideTips()
|
||||
end
|
||||
return SoldierEffectDesCtrl
|
||||
Reference in New Issue
Block a user