Core/Spells: Fix cooldown of Bone Shield

Closes #1370
This commit is contained in:
tobmaps
2011-05-13 03:05:35 +07:00
parent 5652400557
commit a687c867e9
4 changed files with 18 additions and 2 deletions
+13 -1
View File
@@ -7828,7 +7828,7 @@ bool Unit::HandleModDamagePctTakenAuraProc(Unit *pVictim, uint32 /*damage*/, Aur
// Used in case when access to whole aura is needed
// All procs should be handled like this...
bool Unit::HandleAuraProc(Unit * pVictim, uint32 damage, Aura * triggeredByAura, SpellEntry const * procSpell, uint32 /*procFlag*/, uint32 procEx, uint32 /*cooldown*/, bool * handled)
bool Unit::HandleAuraProc(Unit * pVictim, uint32 damage, Aura * triggeredByAura, SpellEntry const * procSpell, uint32 /*procFlag*/, uint32 procEx, uint32 cooldown, bool * handled)
{
SpellEntry const *dummySpell = triggeredByAura->GetSpellProto();
@@ -8013,6 +8013,18 @@ bool Unit::HandleAuraProc(Unit * pVictim, uint32 damage, Aura * triggeredByAura,
switch(dummySpell->Id)
{
// Bone Shield cooldown
case 49222:
{
*handled = true;
if (cooldown && GetTypeId() == TYPEID_PLAYER)
{
if (ToPlayer()->HasSpellCooldown(100000))
return false;
ToPlayer()->AddSpellCooldown(100000, 0, time(NULL) + cooldown);
}
return true;
}
// Hungering Cold aura drop
case 51209:
*handled = true;