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:
@@ -9,7 +9,8 @@ SideBannerCtrl._mapNodeConfig = {
|
||||
goEntry = {},
|
||||
goReward = {},
|
||||
goFavour = {},
|
||||
goAchievement = {}
|
||||
goAchievement = {},
|
||||
goItem = {}
|
||||
}
|
||||
SideBannerCtrl._mapEventConfig = {}
|
||||
function SideBannerCtrl:Popup(tbList)
|
||||
@@ -59,6 +60,8 @@ function SideBannerCtrl:CreateBanner(mapData)
|
||||
return self:CreateFavour(mapData)
|
||||
elseif mapData.nType == AllEnum.SideBaner.Achievement then
|
||||
return self:CreateAchievement(mapData)
|
||||
elseif mapData.nType == AllEnum.SideBaner.Item then
|
||||
return self:CreateItem(mapData)
|
||||
end
|
||||
end
|
||||
function SideBannerCtrl:CreateEntry(mapData)
|
||||
@@ -214,6 +217,27 @@ function SideBannerCtrl:CreateAchievement(mapData)
|
||||
}
|
||||
return mapAfter
|
||||
end
|
||||
function SideBannerCtrl:CreateItem(mapData)
|
||||
local goItem = instantiate(self._mapNode.goItem, self._mapNode.rtContent)
|
||||
goItem:SetActive(true)
|
||||
local trRoot = goItem.transform:Find("AnimRoot")
|
||||
local txtTitle = trRoot:Find("imgBg/txtTitle"):GetComponent("TMP_Text")
|
||||
local aniItem = trRoot:GetComponent("Animator")
|
||||
local txtItemCount = trRoot:Find("imgBg/txtItemCount"):GetComponent("TMP_Text")
|
||||
local imgItemIcon = trRoot:Find("imgBg/imgItemIcon"):GetComponent("Image")
|
||||
local mapCfg = ConfigTable.GetData_Item(mapData.mapReward.id)
|
||||
if mapCfg then
|
||||
self:SetPngSprite(imgItemIcon, mapCfg.Icon)
|
||||
end
|
||||
NovaAPI.SetTMPText(txtItemCount, "×" .. mapData.mapReward.count)
|
||||
NovaAPI.SetTMPText(txtTitle, ConfigTable.GetUIText("GachaItemTIpsTitle"))
|
||||
local mapAfter = {
|
||||
animator = aniItem,
|
||||
transform = trRoot,
|
||||
height = 140
|
||||
}
|
||||
return mapAfter
|
||||
end
|
||||
function SideBannerCtrl:ProcessList(tbList)
|
||||
table.sort(tbList, function(a, b)
|
||||
return a.nType < b.nType
|
||||
|
||||
Reference in New Issue
Block a user