Core/Spells: Implemented caster-is-moving aoe radius bonus and SPELL_ATTR9_NO_MOVEMENT_RADIUS_BONUS

Port From (https://github.com/TrinityCore/TrinityCore/commit/321f3cc4a7a59874c73ab82d57c2f1c76a820396)
This commit is contained in:
Hondacrx
2024-08-31 17:41:27 -04:00
parent b4c955379f
commit a964b9c7f8
2 changed files with 6 additions and 2 deletions
+4
View File
@@ -4273,6 +4273,10 @@ namespace Game.Spells
Player modOwner = caster.GetSpellModOwner();
if (modOwner != null)
modOwner.ApplySpellMod(_spellInfo, SpellModOp.Radius, ref radius, spell);
if (!_spellInfo.HasAttribute(SpellAttr9.NoMovementRadiusBonus))
if (casterUnit != null && casterUnit.IsMoving() && !casterUnit.IsWalking())
radius += 2.0f;
}
return radius;