Core/Spells: rework part 3: spells only handle at most one UnitAura and one DynObjAura during its lifetime

Port From (https://github.com/TrinityCore/TrinityCore/commit/f3548d45d0a74203ef6f5c7282c31ba794ddf7a1)
This commit is contained in:
hondacrx
2021-08-28 17:03:47 -04:00
parent 5ff5fb7d3f
commit 091272755c
8 changed files with 467 additions and 283 deletions
+4 -1
View File
@@ -89,7 +89,10 @@ namespace Game.Chat
if (spellInfo != null)
{
ObjectGuid castId = ObjectGuid.Create(HighGuid.Cast, SpellCastSource.Normal, target.GetMapId(), spellId, target.GetMap().GenerateLowGuid(HighGuid.Cast));
Aura.TryRefreshStackOrCreate(spellInfo, castId, SpellConst.MaxEffectMask, target, target, target.GetMap().GetDifficultyID());
AuraCreateInfo createInfo = new(castId, spellInfo, target.GetMap().GetDifficultyID(), SpellConst.MaxEffectMask, target);
createInfo.SetCaster(target);
Aura.TryRefreshStackOrCreate(createInfo);
}
return true;