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:
@@ -117,7 +117,14 @@ function AutoBattleCtrl:OnClick_AutoBattleClose()
|
||||
end
|
||||
self.animator:Play("AutoBattle_Close")
|
||||
end
|
||||
function AutoBattleCtrl:OnEvent_InputEnable(bEnable)
|
||||
function AutoBattleCtrl:OnEvent_InputEnable(bEnable, bEnableByTrans)
|
||||
if bEnableByTrans == true then
|
||||
if bEnable == true and self.ENABLE == false then
|
||||
return
|
||||
end
|
||||
else
|
||||
self.ENABLE = bEnable
|
||||
end
|
||||
if self.nType == GameEnum.worldLevelType.PrologueBattleLevel then
|
||||
self.gameObject.transform.localScale = Vector3.zero
|
||||
self._mapNode.btnAutoBattleOpen.interactable = false
|
||||
|
||||
@@ -353,7 +353,14 @@ end
|
||||
function BattleDashboardCtrl:OnEvent_LoadLevelRefresh()
|
||||
self:Refresh(AdventureModuleHelper.GetCurrentActivePlayer())
|
||||
end
|
||||
function BattleDashboardCtrl:OnEvent_InputEnable(bEnable)
|
||||
function BattleDashboardCtrl:OnEvent_InputEnable(bEnable, bEnableByTrans)
|
||||
if bEnableByTrans == true then
|
||||
if bEnable == true and self.ENABLE == false then
|
||||
return
|
||||
end
|
||||
else
|
||||
self.ENABLE = bEnable
|
||||
end
|
||||
NovaAPI.DispatchEventWithData("BlockTouchEffect", nil, {bEnable})
|
||||
self:SetAllVisible(bEnable == true, true)
|
||||
NovaAPI.SetRealButtonActive("Fire1", bEnable and self.tbDefine_SkillBtn[1].skillBtnCtrl:GetBtnVisible())
|
||||
@@ -581,11 +588,13 @@ function BattleDashboardCtrl:Add_Skill_EntityEvent(nPlayerId)
|
||||
EventManager.AddEntityEvent("SkillBind", nPlayerId, self, self.OnEvent_SkillBind)
|
||||
EventManager.AddEntityEvent("SyncSkillBtnToLua", nPlayerId, self, self.OnEvent_SyncSkillBtnToLua)
|
||||
EventManager.AddEntityEvent("SkillUseableByActionKey", nPlayerId, self, self.OnEvent_SkillEnableByActionKey)
|
||||
EventManager.AddEntityEvent("SkillResidentHint", nPlayerId, self, self.OnEvent_SkillResidentHint)
|
||||
end
|
||||
function BattleDashboardCtrl:Remove_Skill_EntityEvent(nPlayerId)
|
||||
EventManager.RemoveEntityEvent("SkillBind", nPlayerId, self, self.OnEvent_SkillBind)
|
||||
EventManager.RemoveEntityEvent("SyncSkillBtnToLua", nPlayerId, self, self.OnEvent_SyncSkillBtnToLua)
|
||||
EventManager.RemoveEntityEvent("SkillUseableByActionKey", nPlayerId, self, self.OnEvent_SkillEnableByActionKey)
|
||||
EventManager.RemoveEntityEvent("SkillResidentHint", nPlayerId, self, self.OnEvent_SkillResidentHint)
|
||||
end
|
||||
function BattleDashboardCtrl:Add_SupportSkill_EntityEvent(nPlayerId, nIdx)
|
||||
EventManager.AddEntityEvent("SkillBind", nPlayerId, self, self.OnEvent_SkillBind)
|
||||
@@ -595,6 +604,7 @@ function BattleDashboardCtrl:Add_SupportSkill_EntityEvent(nPlayerId, nIdx)
|
||||
else
|
||||
EventManager.AddEntityEvent("SkillUseableByActionKey", nPlayerId, self, self.OnEvent_Support2SkillEnableByActionKey)
|
||||
end
|
||||
EventManager.AddEntityEvent("SkillResidentHint", nPlayerId, self, self.OnEvent_SupportSkillResidentHint)
|
||||
end
|
||||
function BattleDashboardCtrl:Remove_SupportSkill_EntityEvent(nPlayerId, nIdx)
|
||||
EventManager.RemoveEntityEvent("SkillBind", nPlayerId, self, self.OnEvent_SkillBind)
|
||||
@@ -604,6 +614,7 @@ function BattleDashboardCtrl:Remove_SupportSkill_EntityEvent(nPlayerId, nIdx)
|
||||
else
|
||||
EventManager.RemoveEntityEvent("SkillUseableByActionKey", nPlayerId, self, self.OnEvent_Support2SkillEnableByActionKey)
|
||||
end
|
||||
EventManager.RemoveEntityEvent("SkillResidentHint", nPlayerId, self, self.OnEvent_SupportSkillResidentHint)
|
||||
end
|
||||
function BattleDashboardCtrl:OnEvent_SkillBind(nActionId, nSkillId, nCharId)
|
||||
local data
|
||||
@@ -713,6 +724,22 @@ function BattleDashboardCtrl:OnEvent_Support2SkillEnableByActionKey(nActionId, b
|
||||
data.skillBtnCtrl:SetBtnEnable(bEnable)
|
||||
end
|
||||
end
|
||||
function BattleDashboardCtrl:OnEvent_SkillResidentHint(nSkillId, bEnable)
|
||||
for k, v in pairs(self.tbDefine_SkillBtn) do
|
||||
if v.nSkillId == nSkillId and v.skillBtnCtrl ~= nil then
|
||||
v.skillBtnCtrl:Set_LightGroup(bEnable == true)
|
||||
return
|
||||
end
|
||||
end
|
||||
end
|
||||
function BattleDashboardCtrl:OnEvent_SupportSkillResidentHint(nSkillId, bEnable)
|
||||
for k, v in pairs(self.tbDefine_SupportSkillBtn) do
|
||||
if v.nSkillId == nSkillId and v.skillBtnCtrl ~= nil then
|
||||
v.skillBtnCtrl:Set_LightGroup(bEnable == true)
|
||||
return
|
||||
end
|
||||
end
|
||||
end
|
||||
function BattleDashboardCtrl:OnBtn_ClickHand(btn)
|
||||
if self.bInteractiveInCD == true then
|
||||
return
|
||||
|
||||
@@ -628,7 +628,7 @@ function BossHUDCtrl:RefreshUI(bossId, nDataId, nType, nBloodType)
|
||||
self:SetHp(self.nBeforeHp, self.nBeforeHpMax)
|
||||
end
|
||||
function BossHUDCtrl:OpenUI(bossId, nDataId, nType, nBloodType, bRefresh)
|
||||
if self.bossId ~= 0 and self.bossId ~= nil and bReinit then
|
||||
if self.bossId ~= 0 and self.bossId ~= nil then
|
||||
printError(string.format("boss血条已被EntityId为%d绑定 %d重复绑定不生效", self.bossId, bossId))
|
||||
return
|
||||
end
|
||||
|
||||
@@ -28,9 +28,9 @@ BossPanelCtrl._mapEventConfig = {
|
||||
RefreshCenterHpBar = "OnEvent_RefreshCenterHpBar",
|
||||
MonsterBossDead = "OnEvent_MonsterBossDead",
|
||||
ShowCenterHpBar = "OnEvent_ShowCenterHpBar",
|
||||
InputEnable = "OnEvent_InputEnable",
|
||||
Level_Settlement = "OnEvent_ResetBossHUD",
|
||||
ResetBossHUD = "OnEvent_ResetBossHUD",
|
||||
InputEnable = "OnEvent_InputEnable",
|
||||
ADVENTURE_LEVEL_UNLOAD_COMPLETE = "OnEvent_ResetBossHUD"
|
||||
}
|
||||
function BossPanelCtrl:Awake()
|
||||
@@ -154,6 +154,10 @@ function BossPanelCtrl:RefreshBossPanel(bRefresh)
|
||||
self.nLastBossCount = #self.tbBoss
|
||||
end
|
||||
function BossPanelCtrl:CloseUI()
|
||||
if #self.tbBoss == 0 and next(self.tbBossCtrl) == nil then
|
||||
self._mapNode.BossCanvas.enabled = false
|
||||
return
|
||||
end
|
||||
NovaAPI.SetCanvasGroupAlpha(self._mapNode.BossCanvasGroup, 1)
|
||||
self.bossHUDCloseAnimTweener = Sequence()
|
||||
self.bossHUDCloseAnimTweener:Append(self._mapNode.BossCanvasGroup:DOFade(0, 0.5))
|
||||
|
||||
@@ -66,7 +66,14 @@ function MainBattleMenuCtrl:OnBtn_FullMap()
|
||||
AdventureModuleHelper.SetMapCameraActive(false)
|
||||
end
|
||||
end
|
||||
function MainBattleMenuCtrl:OnEvent_InputEnable(bEnable)
|
||||
function MainBattleMenuCtrl:OnEvent_InputEnable(bEnable, bEnableByTrans)
|
||||
if bEnableByTrans == true then
|
||||
if bEnable == true and self.ENABLE == false then
|
||||
return
|
||||
end
|
||||
else
|
||||
self.ENABLE = bEnable
|
||||
end
|
||||
NovaAPI.SetCanvasGroupAlpha(self._mapNode.canvas_group, bEnable == true and 1 or 0)
|
||||
NovaAPI.SetCanvasGroupInteractable(self._mapNode.canvas_group, bEnable == true)
|
||||
NovaAPI.SetCanvasGroupBlocksRaycasts(self._mapNode.canvas_group, bEnable == true)
|
||||
|
||||
@@ -1,6 +1,8 @@
|
||||
local SkillBtnCtrl = class("SkillBtnCtrl", BaseCtrl)
|
||||
local WwiseAudioMgr = CS.WwiseAudioManager.Instance
|
||||
local LocalSettingData = require("GameCore.Data.LocalSettingData")
|
||||
local GameResourceLoader = require("Game.Common.Resource.GameResourceLoader")
|
||||
local ResType = GameResourceLoader.ResType
|
||||
local NormalCDSize = 34
|
||||
local eftColor = {
|
||||
[1] = "#00B7FF",
|
||||
@@ -36,6 +38,11 @@ SkillBtnCtrl._mapNodeConfig = {
|
||||
sComponentName = "Image"
|
||||
},
|
||||
ICON = {sComponentName = "Image"},
|
||||
LightLoop = {
|
||||
sNodeName = "LightLoop_",
|
||||
nCount = 6,
|
||||
sComponentName = "GameObject"
|
||||
},
|
||||
transformCD = {sNodeName = "CD", sComponentName = "Transform"},
|
||||
TMP_CD = {sNodeName = "CD_TMP", sComponentName = "TMP_Text"},
|
||||
transformCharge = {sNodeName = "Charge", sComponentName = "Transform"},
|
||||
@@ -122,6 +129,9 @@ function SkillBtnCtrl:InitSkillBtn(EET, icon, bShowSection, charId, actionId, bI
|
||||
NovaAPI.SetImageColor(self._mapNode.imageFXFire, _colorFire)
|
||||
NovaAPI.SetImageColor(self._mapNode.Img_Charge_glow, _color)
|
||||
self:SetAtlasSprite(self._mapNode.imageType, "15_battle", "skill_btn_b_type_" .. tostring(EET))
|
||||
local sPath = Settings.AB_ROOT_PATH .. "UI/Battle/FX/Textures/btnSkill_qte_0" .. tostring(EET) .. ".png"
|
||||
local sp = GameResourceLoader.LoadAsset(ResType.Any, sPath, typeof(Sprite), "UI", self._panel._nPanelId)
|
||||
NovaAPI.SetImageSpriteAsset(self._mapNode.imageQteLoading, sp)
|
||||
end
|
||||
self:SetPngSprite(self._mapNode.ICON, icon)
|
||||
self._mapNode.transformCharge.localScale = Vector3.zero
|
||||
@@ -134,6 +144,9 @@ function SkillBtnCtrl:InitSkillBtn(EET, icon, bShowSection, charId, actionId, bI
|
||||
else
|
||||
self.parentCanvasGroup = self.gameObject.transform.parent.parent:GetComponent("CanvasGroup")
|
||||
end
|
||||
for i, v in ipairs(self._mapNode.LightLoop) do
|
||||
v:SetActive(bEnable)
|
||||
end
|
||||
end
|
||||
function SkillBtnCtrl:SetEmptySkillBtn()
|
||||
self._mapNode.CanvasGroupMain.gameObject:SetActive(false)
|
||||
@@ -295,6 +308,9 @@ function SkillBtnCtrl:Set_SkillHintActive(bActive)
|
||||
self._mapNode.transformQTE.localScale = bActive == true and Vector3.one or Vector3.zero
|
||||
self._mapNode.imageQteLoading.transform.localScale = bActive == true and Vector3.zero or Vector3.one
|
||||
end
|
||||
function SkillBtnCtrl:Set_LightGroup(bEnable)
|
||||
self._mapNode.LightLoop[self.EET]:SetActive(bEnable)
|
||||
end
|
||||
function SkillBtnCtrl:SetSupSkillStateByUltimate(bForbidden)
|
||||
self._mapNode.transformX.localScale = bForbidden == true and Vector3.one or Vector3.zero
|
||||
self._mapNode.transformCD.gameObject:SetActive(not bForbidden)
|
||||
|
||||
@@ -0,0 +1,60 @@
|
||||
local TraceHuntBattlePanel = class("TraceHuntBattlePanel", BasePanel)
|
||||
local GamepadUIManager = require("GameCore.Module.GamepadUIManager")
|
||||
TraceHuntBattlePanel.OpenMinMap = true
|
||||
TraceHuntBattlePanel._bAddToBackHistory = false
|
||||
TraceHuntBattlePanel._tbDefine = {
|
||||
{
|
||||
sPrefabPath = "Battle/BattleDashboard.prefab",
|
||||
sCtrlName = "Game.UI.Battle.BattleDashboardCtrl"
|
||||
},
|
||||
{
|
||||
sPrefabPath = "Battle/MainBattleMenu.prefab",
|
||||
sCtrlName = "Game.UI.Battle.MainBattleMenuCtrl"
|
||||
},
|
||||
{
|
||||
sPrefabPath = "Battle/AdventureMainUI/AdventureMainUI.prefab",
|
||||
sCtrlName = "Game.UI.Battle.MainBattleCtrl"
|
||||
},
|
||||
{
|
||||
sPrefabPath = "Battle/AdventureMainUI/BattlePopupTips.prefab",
|
||||
sCtrlName = "Game.UI.Battle.BattlePopupTipsCtrl"
|
||||
},
|
||||
{
|
||||
sPrefabPath = "Play_TraceHuntBattle/TraceHuntLevelInfo.prefab",
|
||||
sCtrlName = "Game.UI.TraceHunt.TraceHuntLevelInfoCtrl"
|
||||
},
|
||||
{
|
||||
sPrefabPath = "Battle/SkillHintIndicators.prefab",
|
||||
sCtrlName = "Game.UI.Battle.SkillHintIndicator.HintIndicators"
|
||||
},
|
||||
{
|
||||
sPrefabPath = "Play_TraceHuntBattle/TraceHuntPausePanel.prefab",
|
||||
sCtrlName = "Game.UI.TraceHunt.TraceHuntPauseCtrl"
|
||||
},
|
||||
{
|
||||
sPrefabPath = "Battle/SubSkillDisplay.prefab",
|
||||
sCtrlName = "Game.UI.Battle.SubSkillDisplay.SubSkillDisplayCtrl"
|
||||
}
|
||||
}
|
||||
function TraceHuntBattlePanel:Awake()
|
||||
GamepadUIManager.EnterAdventure()
|
||||
GamepadUIManager.EnableGamepadUI("BattleMenu", {})
|
||||
self.BattleType = GameEnum.worldLevelType.TraceHunt
|
||||
end
|
||||
function TraceHuntBattlePanel:OnEnable()
|
||||
local wait = function()
|
||||
coroutine.yield(CS.UnityEngine.WaitForEndOfFrame())
|
||||
EventManager.Hit(EventId.OpenPanel, PanelId.Hud)
|
||||
EventManager.Hit(EventId.ClosePanel, PanelId.MainlineFormation)
|
||||
EventManager.Hit(EventId.ClosePanel, PanelId.RegionBossFormation)
|
||||
end
|
||||
cs_coroutine.start(wait)
|
||||
end
|
||||
function TraceHuntBattlePanel:OnAfterEnter()
|
||||
EventManager.Hit(EventId.SubSkillDisplayInit, self._tbParam[1])
|
||||
end
|
||||
function TraceHuntBattlePanel:OnDisable()
|
||||
GamepadUIManager.DisableGamepadUI("BattleMenu")
|
||||
GamepadUIManager.QuitAdventure()
|
||||
end
|
||||
return TraceHuntBattlePanel
|
||||
Reference in New Issue
Block a user