mirror of
https://github.com/mod-playerbots/azerothcore-wotlk.git
synced 2026-01-13 17:19:07 +00:00
fix(Core/Spells): several improvements to cooldowns (#7559)
- Reworked spell category cooldowns. - Implemented category cooldowns for pets. - Properly shows pet spell cooldowns in player's UI. - Corrected pet spell cooldowns with infinity duration. - Do not add/remove infinity spell cooldown on aura apply/remove if casted by item. - Closes #5263
This commit is contained in:
@@ -1451,7 +1451,7 @@ void TriggerBurningPitch(Creature* c)
|
||||
if (!c->HasSpellCooldown(spellId))
|
||||
{
|
||||
c->CastSpell((Unit*)nullptr, spellId, false);
|
||||
c->_AddCreatureSpellCooldown(spellId, urand(3000, 4000));
|
||||
c->_AddCreatureSpellCooldown(spellId, 0, urand(3000, 4000));
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1917,7 +1917,7 @@ public:
|
||||
return;
|
||||
|
||||
me->CastSpell((Unit*)nullptr, spellId, true);
|
||||
me->_AddCreatureSpellCooldown(spellId, 9000);
|
||||
me->_AddCreatureSpellCooldown(spellId, 0, 9000);
|
||||
}
|
||||
|
||||
bool CanAIAttack(const Unit* /*target*/) const override
|
||||
|
||||
@@ -304,8 +304,8 @@ public:
|
||||
case EVENT_SPELL_ROAR:
|
||||
Talk(EMOTE_ROAR);
|
||||
|
||||
me->_AddCreatureSpellCooldown(SPELL_STAGGERING_ROAR, 0);
|
||||
me->_AddCreatureSpellCooldown(SPELL_DREADFUL_ROAR, 0);
|
||||
me->_AddCreatureSpellCooldown(SPELL_STAGGERING_ROAR, 0, 0);
|
||||
me->_AddCreatureSpellCooldown(SPELL_DREADFUL_ROAR, 0, 0);
|
||||
|
||||
if (me->GetDisplayId() == DISPLAYID_DEFAULT)
|
||||
me->CastSpell((Unit*)nullptr, SPELL_STAGGERING_ROAR, false);
|
||||
|
||||
Reference in New Issue
Block a user