Core/AI: OnSpellCast, OnSpellFailed, OnSpellStart hooks
Port From (https://github.com/TrinityCore/TrinityCore/commit/050f55b62fded4cc73b76e42d56d98ea950cc26a)
This commit is contained in:
@@ -3226,6 +3226,20 @@ namespace Game.AI
|
||||
}
|
||||
break;
|
||||
}
|
||||
case SmartEvents.OnSpellCast:
|
||||
case SmartEvents.OnSpellFailed:
|
||||
case SmartEvents.OnSpellStart:
|
||||
{
|
||||
if (spell == null)
|
||||
return;
|
||||
|
||||
if (spell.Id != e.Event.spellCast.spell)
|
||||
return;
|
||||
|
||||
RecalcTimer(e, e.Event.spellCast.cooldownMin, e.Event.spellCast.cooldownMax);
|
||||
ProcessAction(e, null, 0, 0, bvar, spell);
|
||||
break;
|
||||
}
|
||||
case SmartEvents.OocLos:
|
||||
{
|
||||
if (_me == null || _me.IsEngaged())
|
||||
|
||||
Reference in New Issue
Block a user