[8426] Use upper/lower iterator pairs as result instead 2 function calls. Author: VladimirMangos

--HG--
branch : trunk
This commit is contained in:
megamage committed 2009-08-27 20:27:55 -05:00
1 parent eeb18e51bb
commit dd72b5524c
8 files changed
+141 -181

No files matched your search

+2 -4
View File
@@ -2371,10 +2371,8 @@ void ObjectMgr::LoadItemRequiredTarget()
if (pItemProto->Spells[i].SpellTrigger == ITEM_SPELLTRIGGER_ON_USE ||
pItemProto->Spells[i].SpellTrigger == ITEM_SPELLTRIGGER_ON_NO_DELAY_USE)
{
SpellScriptTarget::const_iterator lower = spellmgr.GetBeginSpellScriptTarget(pSpellInfo->Id);
SpellScriptTarget::const_iterator upper = spellmgr.GetEndSpellScriptTarget(pSpellInfo->Id);
if (lower != upper)
SpellScriptTargetBounds bounds = spellmgr.GetSpellScriptTargetBounds(pSpellInfo->Id);
if (bounds.first != bounds.second)
break;
for (int j = 0; j < 3; ++j)