Merge branch 'dev' of git.juzugame.com:b6-client/b6-lua into dev

This commit is contained in:
chenxi 2023-04-23 19:20:47 +08:00
commit 88e64acf32
3 changed files with 21 additions and 8 deletions

View File

@ -307,7 +307,8 @@ GConst.UI_EFFECT_ORDER = {
LEVEL2 = 40,
LEVEL3 = 60,
LEVEL4 = 80,
LEVEL5 = 100
LEVEL5 = 100,
LEVEL_10 = 10,
}
GConst.LANGUAGE = {

View File

@ -598,7 +598,8 @@ BattleConst.OUTLINE_SFX = {
[BattleConst.ELEMENT_TYPE.YELLOW] = "sfx_piece_qizi_b02",
[BattleConst.ELEMENT_TYPE.GREEN] = "sfx_piece_qizi_b04",
[BattleConst.ELEMENT_TYPE.BLUE] = "sfx_piece_qizi_b05",
[BattleConst.ELEMENT_TYPE.PURPLE] = "sfx_piece_qizi_b01"
[BattleConst.ELEMENT_TYPE.PURPLE] = "sfx_piece_qizi_b01",
skill = "sfx_piece_qizi_b06",
}
BattleConst.LINE_SFX = "assets/prefabs/effects/battle/sfx_piece_line_b01.prefab"

View File

@ -120,11 +120,19 @@ function GridCell:showHighLight(show, mainElementType, parentUI)
local find = false
for type, obj in pairs(self.outLineSfxObjs) do
if show and type == elementType then
find = true
if self.lastShowHlElementType ~= elementType then
self.lastShowHlElementType = elementType
obj:setActive(true)
if show then
if skillId then
if type == "skill" then
find = true
end
elseif elementType == type then
find = true
end
if find then
if self.lastShowHlElementType ~= elementType then
self.lastShowHlElementType = elementType
obj:setActive(true)
end
end
else
obj:setActive(false)
@ -165,9 +173,12 @@ function GridCell:setOrder(uiOder)
local uiMap = self:getUIMap()
for elementType, name in pairs(GConst.BattleConst.OUTLINE_SFX) do
local obj = uiMap["grid_cell.touch_node.ani_node.effect_node." .. name]
obj:getComponent(GConst.TYPEOF_UNITY_CLASS.BF_EFFECT_HELPER):SetSortingOrder(uiOder, GConst.UI_EFFECT_ORDER.LEVEL1)
obj:getComponent(GConst.TYPEOF_UNITY_CLASS.BF_EFFECT_HELPER):SetSortingOrder(uiOder, GConst.UI_EFFECT_ORDER.LEVEL_10)
obj:setActive(false)
end
local skillEffect = uiMap["grid_cell.touch_node.ani_node.effect_node.sfx_piece_qizi_b06"]
skillEffect:getComponent(GConst.TYPEOF_UNITY_CLASS.BF_EFFECT_HELPER):SetSortingOrder(uiOder, GConst.UI_EFFECT_ORDER.LEVEL_10)
skillEffect:setActive(false)
end
return GridCell