mirror of
https://github.com/TrinityCore/TrinityCore.git
synced 2026-01-20 17:27:36 +01:00
*Cleanup and optimization
--HG-- branch : trunk
This commit is contained in:
@@ -305,9 +305,9 @@ void InstanceData::DoSendNotifyToInstance(const char *format, ...)
|
||||
InstanceMap::PlayerList::const_iterator i;
|
||||
|
||||
if (!PlayerList.isEmpty())
|
||||
for (i = PlayerList.begin(); i != PlayerList.end(); ++i)
|
||||
if ((*i).getSource() && (*i).getSource()->GetSession())
|
||||
(*i).getSource()->GetSession()->SendNotification(format);
|
||||
for (Map::PlayerList::const_iterator i = PlayerList.begin(); i != PlayerList.end(); ++i)
|
||||
if (i->getSource() && i->getSource()->GetSession())
|
||||
i->getSource()->GetSession()->SendNotification(format);
|
||||
}
|
||||
|
||||
// Complete Achievement for all players in instance
|
||||
@@ -330,5 +330,6 @@ void InstanceData::DoRemoveAurasDueToSpellOnPlayers(uint32 spell)
|
||||
|
||||
if (!PlayerList.isEmpty())
|
||||
for (Map::PlayerList::const_iterator i = PlayerList.begin(); i != PlayerList.end(); ++i)
|
||||
if (i->getSource() && i->getSource()->HasAura(spell)) i->getSource()->RemoveAurasDueToSpell(spell);
|
||||
if (i->getSource())
|
||||
i->getSource()->RemoveAurasDueToSpell(spell);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user