fix bug spawn a lot of fly gfx

This commit is contained in:
VDH
2026-04-08 14:31:04 +07:00
parent e8c567a803
commit 445a024015
2 changed files with 13 additions and 1 deletions
@@ -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
@@ -329,6 +329,7 @@ namespace BrewMonster
/// </summary>
private void SpawnFlyGfx()
{
if (!m_bShowFlyGfx) return;
if (m_pComposer == null)
{
@@ -411,6 +412,7 @@ namespace BrewMonster
/// </summary>
private void SpawnHitGfx(Vector3 vTarget)
{
if (!m_bShowHitGfx) return;
if (m_pComposer == null)
{