Small cleanup/corrections

--HG--
branch : trunk
This commit is contained in:
Shocker
2010-08-27 04:55:49 +03:00
parent c247de12a9
commit 35066fdb6a
5 changed files with 8 additions and 8 deletions
+2 -2
View File
@@ -3535,13 +3535,13 @@ void Unit::FinishSpell(CurrentSpellTypes spellType, bool ok /*= true*/)
spell->finish(ok);
}
bool Unit::IsNonMeleeSpellCasted(bool withDelayed, bool skipChanneled, bool skipAutorepeat, bool isAutoshoot, bool checkInstant) const
bool Unit::IsNonMeleeSpellCasted(bool withDelayed, bool skipChanneled, bool skipAutorepeat, bool isAutoshoot, bool skipInstant) const
{
// We don't do loop here to explicitly show that melee spell is excluded.
// Maybe later some special spells will be excluded too.
// if checkInstant then instant spells shouldn't count as being casted
if (checkInstant && m_currentSpells[CURRENT_GENERIC_SPELL] && !m_currentSpells[CURRENT_GENERIC_SPELL]->GetCastTime())
if (!skipInstant && m_currentSpells[CURRENT_GENERIC_SPELL] && !m_currentSpells[CURRENT_GENERIC_SPELL]->GetCastTime())
return false;
// generic spells are casted when they are not finished and not delayed
+1 -1
View File
@@ -1694,7 +1694,7 @@ class Unit : public WorldObject
// set withDelayed to true to account delayed spells as casted
// delayed+channeled spells are always accounted as casted
// we can skip channeled or delayed checks using flags
bool IsNonMeleeSpellCasted(bool withDelayed, bool skipChanneled = false, bool skipAutorepeat = false, bool isAutoshoot = false, bool checkInstant = false) const;
bool IsNonMeleeSpellCasted(bool withDelayed, bool skipChanneled = false, bool skipAutorepeat = false, bool isAutoshoot = false, bool skipInstant = true) const;
// set withDelayed to true to interrupt delayed spells too
// delayed+channeled spells are always interrupted