优化局内技能显示
This commit is contained in:
parent
4c8eff015e
commit
619bfad50a
@ -46,6 +46,13 @@ function BattleBoardSkillTips:onLoadRootComplete()
|
|||||||
self.originPivot = tipsBgTransform.pivot
|
self.originPivot = tipsBgTransform.pivot
|
||||||
self.originAnchoredPosition = tipsBgTransform.anchoredPosition
|
self.originAnchoredPosition = tipsBgTransform.anchoredPosition
|
||||||
self.originLocalPosition = tipsBgTransform.localPosition
|
self.originLocalPosition = tipsBgTransform.localPosition
|
||||||
|
|
||||||
|
self.bg:addClickListener(function()
|
||||||
|
local cfg = ConfigManager:getConfig("skill")[self.boardSkillEntity:getSkillId()]
|
||||||
|
if cfg.buff_id and #cfg.buff_id > 0 then
|
||||||
|
ModuleManager.TipsManager:showSkillTips(self.bg, cfg.buff_id)
|
||||||
|
end
|
||||||
|
end)
|
||||||
end
|
end
|
||||||
|
|
||||||
function BattleBoardSkillTips:onRefresh()
|
function BattleBoardSkillTips:onRefresh()
|
||||||
@ -79,7 +86,8 @@ function BattleBoardSkillTips:onRefresh()
|
|||||||
local value = self.battleData:getSelectSkillMap(self.side)[skillId].value or 0
|
local value = self.battleData:getSelectSkillMap(self.side)[skillId].value or 0
|
||||||
cell:refresh(skillId, count)
|
cell:refresh(skillId, count)
|
||||||
cell:addClickListener(function()
|
cell:addClickListener(function()
|
||||||
ModuleManager.TipsManager:showDescTips(ModuleManager.HeroManager:getSkillRogueDesc(skillId, value), cell:getBaseObject())
|
local cfg = ConfigManager:getConfig("skill_rogue")[skillId]
|
||||||
|
ModuleManager.TipsManager:showSkillTips(cell:getBaseObject(), cfg.buff_id, skillId)
|
||||||
end)
|
end)
|
||||||
else
|
else
|
||||||
cell:getBaseObject():setActive(false)
|
cell:getBaseObject():setActive(false)
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user