mirror of
https://github.com/mangosfour/server.git
synced 2025-12-18 01:37:01 +00:00
[10074] Add IsPassive(SpellEntry*) function and use in cases wjern entry already known.
Some other small code cleanups
This commit is contained in:
parent
6ca609629c
commit
07a931e141
12 changed files with 35 additions and 33 deletions
|
|
@ -191,7 +191,7 @@ void WorldSession::HandlePetAction( WorldPacket & recv_data )
|
|||
}
|
||||
|
||||
// do not cast not learned spells
|
||||
if(!pet->HasSpell(spellid) || IsPassiveSpell(spellid))
|
||||
if(!pet->HasSpell(spellid) || IsPassiveSpell(spellInfo))
|
||||
return;
|
||||
|
||||
pet->clearUnitState(UNIT_STAT_MOVING);
|
||||
|
|
@ -626,7 +626,7 @@ void WorldSession::HandlePetCastSpellOpcode( WorldPacket& recvPacket )
|
|||
}
|
||||
|
||||
// do not cast not learned spells
|
||||
if (!pet->HasSpell(spellid) || IsPassiveSpell(spellid))
|
||||
if (!pet->HasSpell(spellid) || IsPassiveSpell(spellInfo))
|
||||
return;
|
||||
|
||||
SpellCastTargets targets;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue