From 445a024015ea2ec1a0dd4938f213dc4d617d1e1b Mon Sep 17 00:00:00 2001 From: VDH Date: Wed, 8 Apr 2026 14:31:04 +0700 Subject: [PATCH] fix bug spawn a lot of fly gfx --- .../PerfectWorld/Scripts/Managers/A3DSkillGfxMan.cs | 12 +++++++++++- .../PerfectWorld/Scripts/Managers/CECSkillGfxMan.cs | 2 ++ 2 files changed, 13 insertions(+), 1 deletion(-) diff --git a/Assets/PerfectWorld/Scripts/Managers/A3DSkillGfxMan.cs b/Assets/PerfectWorld/Scripts/Managers/A3DSkillGfxMan.cs index 0a5ce5450e..85b15e413c 100644 --- a/Assets/PerfectWorld/Scripts/Managers/A3DSkillGfxMan.cs +++ b/Assets/PerfectWorld/Scripts/Managers/A3DSkillGfxMan.cs @@ -151,6 +151,8 @@ namespace BrewMonster pEvent.SetIsCluster(bCluster); pEvent.SetFadeOut(bFadeOut); pEvent.SetGoblinSkill(bIsGoblinSkill); + pEvent.SetShowFlyGfx(!string.IsNullOrEmpty(szFlyGfx)); + pEvent.SetShowHitGfx(!string.IsNullOrEmpty(szHitGfx)); ECMODEL_GFX_PROPERTY Prop = new ECMODEL_GFX_PROPERTY(); if (GetPropertyById(nHostID, ref Prop)) @@ -192,7 +194,9 @@ namespace BrewMonster protected long m_nHostID; protected long m_nTargetID; protected uint m_dwModifier; - protected bool m_bIsGoblinSkill; + protected bool m_bIsGoblinSkill; + protected bool m_bShowFlyGfx; + protected bool m_bShowHitGfx; protected Vector3 m_vHostPos; protected Vector3 m_vTargetPos; @@ -222,6 +226,8 @@ namespace BrewMonster m_enumState = GfxSkillEventState.enumWait; m_bHitGfxInfinite = false; m_bIsGoblinSkill = false; + m_bShowFlyGfx = true; + m_bShowHitGfx = true; m_bTargetDirAndUpExist = false; m_bGfxUseLod = true; m_bGfxDisableCamShake = false; @@ -336,12 +342,16 @@ namespace BrewMonster public void SetModifier(uint dwModifier) { m_dwModifier = dwModifier; } public void SetGoblinSkill(bool bGoblinSkill) { m_bIsGoblinSkill = bGoblinSkill; } public bool GetGoblinSkill() { return m_bIsGoblinSkill; } + public void SetShowFlyGfx(bool b) { m_bShowFlyGfx = b; } + public void SetShowHitGfx(bool b) { m_bShowHitGfx = b; } public void Resume() { //ReleaseGfx(); m_enumState = GfxSkillEventState.enumWait; m_dwCurSpan = 0; + m_bShowFlyGfx = true; + m_bShowHitGfx = true; } // Virtual functions diff --git a/Assets/PerfectWorld/Scripts/Managers/CECSkillGfxMan.cs b/Assets/PerfectWorld/Scripts/Managers/CECSkillGfxMan.cs index ac8cc94512..fcfc388899 100644 --- a/Assets/PerfectWorld/Scripts/Managers/CECSkillGfxMan.cs +++ b/Assets/PerfectWorld/Scripts/Managers/CECSkillGfxMan.cs @@ -329,6 +329,7 @@ namespace BrewMonster /// private void SpawnFlyGfx() { + if (!m_bShowFlyGfx) return; if (m_pComposer == null) { @@ -411,6 +412,7 @@ namespace BrewMonster /// private void SpawnHitGfx(Vector3 vTarget) { + if (!m_bShowHitGfx) return; if (m_pComposer == null) {