diff --git a/Source/Framework/Constants/Spells/SpellConst.cs b/Source/Framework/Constants/Spells/SpellConst.cs index a41642a83..0e38e0043 100644 --- a/Source/Framework/Constants/Spells/SpellConst.cs +++ b/Source/Framework/Constants/Spells/SpellConst.cs @@ -1542,7 +1542,7 @@ namespace Framework.Constants IgnoreCastItem = 0x08, //! Will Not Take Away Cast Item Or Update Related Achievement Criteria IgnoreAuraScaling = 0x10, //! Will Ignore Aura Scaling IgnoreCastInProgress = 0x20, //! Will Not Check If A Current Cast Is In Progress - // reuse = 0x40, // + IgnoreCastTime = 0x40, //! Will always be instantly cast CastDirectly = 0x80, //! In Spell.Prepare, Will Be Cast Directly Without Setting Containers For Executed Spell // reuse = 0x100, // IgnoreSetFacing = 0x200, //! Will Not Adjust Facing To Target (If Any) diff --git a/Source/Game/Spells/Spell.cs b/Source/Game/Spells/Spell.cs index e9ae40690..54c2ec80f 100644 --- a/Source/Game/Spells/Spell.cs +++ b/Source/Game/Spells/Spell.cs @@ -2630,7 +2630,9 @@ namespace Game.Spells // Prepare data for triggers PrepareDataForTriggerSystem(); - m_casttime = CallScriptCalcCastTimeHandlers(m_spellInfo.CalcCastTime(this)); + if (!_triggeredCastFlags.HasFlag(TriggerCastFlags.IgnoreCastTime)) + m_casttime = m_spellInfo.CalcCastTime(this); + m_casttime = CallScriptCalcCastTimeHandlers(m_casttime); SpellCastResult movementResult = SpellCastResult.SpellCastOk; if (m_caster.IsUnit() && m_caster.ToUnit().IsMoving()) diff --git a/Source/Game/Spells/SpellEffects.cs b/Source/Game/Spells/SpellEffects.cs index 567690ba2..92ed336a3 100644 --- a/Source/Game/Spells/SpellEffects.cs +++ b/Source/Game/Spells/SpellEffects.cs @@ -4841,7 +4841,7 @@ namespace Game.Spells if (!spellInfo.HasAttribute(SpellAttr7.CanBeMultiCast)) continue; - CastSpellExtraArgs args = new(TriggerCastFlags.IgnoreGCD | TriggerCastFlags.IgnoreCastInProgress | TriggerCastFlags.CastDirectly | TriggerCastFlags.DontReportCastError); + CastSpellExtraArgs args = new(TriggerCastFlags.IgnoreGCD | TriggerCastFlags.IgnoreCastInProgress | TriggerCastFlags.IgnoreCastTime | TriggerCastFlags.CastDirectly | TriggerCastFlags.DontReportCastError); args.OriginalCastId = m_castId; args.CastDifficulty = GetCastDifficulty(); m_caster.CastSpell(m_caster, spellInfo.Id, args); diff --git a/Source/Scripts/Spells/Priest.cs b/Source/Scripts/Spells/Priest.cs index 514471e96..bb18c8ab0 100644 --- a/Source/Scripts/Spells/Priest.cs +++ b/Source/Scripts/Spells/Priest.cs @@ -3420,7 +3420,7 @@ namespace Scripts.Spells.Priest { GetCaster().CastSpell(GetHitUnit(), SpellIds.VampiricTouch, new CastSpellExtraArgs() .SetTriggeringSpell(GetSpell()) - .SetTriggerFlags(TriggerCastFlags.IgnoreGCD | TriggerCastFlags.IgnoreSpellAndCategoryCD | TriggerCastFlags.IgnorePowerAndReagentCost | TriggerCastFlags.IgnoreCastInProgress | TriggerCastFlags.CastDirectly | TriggerCastFlags.DontReportCastError)); + .SetTriggerFlags(TriggerCastFlags.IgnoreGCD | TriggerCastFlags.IgnoreSpellAndCategoryCD | TriggerCastFlags.IgnorePowerAndReagentCost | TriggerCastFlags.IgnoreCastInProgress | TriggerCastFlags.IgnoreCastTime | TriggerCastFlags.DontReportCastError)); } public override void Register()