mirror of
https://github.com/mangosfour/server.git
synced 2025-12-13 22:37:03 +00:00
[6968] Replace check for spell category removed in 3.0.x with spellid.
Should fix not interrupting wand casting by other spell cast. Signed-off-by: ApoC <apoc@nymfe.net>
This commit is contained in:
parent
963c6e5cf7
commit
784cf098b0
4 changed files with 8 additions and 7 deletions
|
|
@ -2786,7 +2786,7 @@ void Unit::_UpdateAutoRepeatSpell()
|
|||
if ( (GetTypeId() == TYPEID_PLAYER && ((Player*)this)->isMoving()) || IsNonMeleeSpellCasted(false,false,true) )
|
||||
{
|
||||
// cancel wand shoot
|
||||
if(m_currentSpells[CURRENT_AUTOREPEAT_SPELL]->m_spellInfo->Category == 351)
|
||||
if(m_currentSpells[CURRENT_AUTOREPEAT_SPELL]->m_spellInfo->Id != SPELL_ID_AUTOSHOT)
|
||||
InterruptSpell(CURRENT_AUTOREPEAT_SPELL);
|
||||
m_AutoRepeatFirstCast = true;
|
||||
return;
|
||||
|
|
@ -2839,7 +2839,7 @@ void Unit::SetCurrentCastedSpell( Spell * pSpell )
|
|||
if ( m_currentSpells[CURRENT_AUTOREPEAT_SPELL] )
|
||||
{
|
||||
// break autorepeat if not Auto Shot
|
||||
if (m_currentSpells[CURRENT_AUTOREPEAT_SPELL]->m_spellInfo->Category == 351)
|
||||
if (m_currentSpells[CURRENT_AUTOREPEAT_SPELL]->m_spellInfo->Id != SPELL_ID_AUTOSHOT)
|
||||
InterruptSpell(CURRENT_AUTOREPEAT_SPELL);
|
||||
m_AutoRepeatFirstCast = true;
|
||||
}
|
||||
|
|
@ -2853,14 +2853,14 @@ void Unit::SetCurrentCastedSpell( Spell * pSpell )
|
|||
|
||||
// it also does break autorepeat if not Auto Shot
|
||||
if ( m_currentSpells[CURRENT_AUTOREPEAT_SPELL] &&
|
||||
m_currentSpells[CURRENT_AUTOREPEAT_SPELL]->m_spellInfo->Category == 351 )
|
||||
m_currentSpells[CURRENT_AUTOREPEAT_SPELL]->m_spellInfo->Id != SPELL_ID_AUTOSHOT )
|
||||
InterruptSpell(CURRENT_AUTOREPEAT_SPELL);
|
||||
} break;
|
||||
|
||||
case CURRENT_AUTOREPEAT_SPELL:
|
||||
{
|
||||
// only Auto Shoot does not break anything
|
||||
if (pSpell->m_spellInfo->Category == 351)
|
||||
if (pSpell->m_spellInfo->Id != SPELL_ID_AUTOSHOT)
|
||||
{
|
||||
// generic autorepeats break generic non-delayed and channeled non-delayed spells
|
||||
InterruptSpell(CURRENT_GENERIC_SPELL,false);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue