*Update to Mangos 6888. Source: Mangos.
*Major change: Make corpse erase async, Avoid DB access on deleting guild member. *Skip 6885 because of performance concern. --HG-- branch : trunk
This commit is contained in:
+9
-9
@@ -2476,7 +2476,7 @@ void Player::SendInitialSpells()
|
||||
|
||||
uint16 spellCooldowns = m_spellCooldowns.size();
|
||||
data << uint16(spellCooldowns);
|
||||
for(SpellCooldowns::const_iterator itr=m_spellCooldowns.begin(); itr!=m_spellCooldowns.end(); itr++)
|
||||
for(SpellCooldowns::const_iterator itr=m_spellCooldowns.begin(); itr!=m_spellCooldowns.end(); ++itr)
|
||||
{
|
||||
SpellEntry const *sEntry = sSpellStore.LookupEntry(itr->first);
|
||||
if(!sEntry)
|
||||
@@ -3298,7 +3298,7 @@ bool Player::_removeSpell(uint16 spell_id)
|
||||
|
||||
Mail* Player::GetMail(uint32 id)
|
||||
{
|
||||
for(PlayerMails::iterator itr = m_mail.begin(); itr != m_mail.end(); itr++)
|
||||
for(PlayerMails::iterator itr = m_mail.begin(); itr != m_mail.end(); ++itr)
|
||||
{
|
||||
if ((*itr)->messageID == id)
|
||||
{
|
||||
@@ -5510,7 +5510,7 @@ void Player::SendInitialReputations()
|
||||
|
||||
RepListID a = 0;
|
||||
|
||||
for (FactionStateList::const_iterator itr = m_factions.begin(); itr != m_factions.end(); itr++)
|
||||
for (FactionStateList::const_iterator itr = m_factions.begin(); itr != m_factions.end(); ++itr)
|
||||
{
|
||||
// fill in absent fields
|
||||
for (; a != itr->first; a++)
|
||||
@@ -6519,7 +6519,7 @@ void Player::DuelComplete(DuelCompleteType type)
|
||||
/* remove auras */
|
||||
std::vector<uint32> auras2remove;
|
||||
AuraMap const& vAuras = duel->opponent->GetAuras();
|
||||
for (AuraMap::const_iterator i = vAuras.begin(); i != vAuras.end(); i++)
|
||||
for (AuraMap::const_iterator i = vAuras.begin(); i != vAuras.end(); ++i)
|
||||
{
|
||||
if (!i->second->IsPositive() && i->second->GetCasterGUID() == GetGUID() && i->second->GetAuraApplyTime() >= duel->startTime)
|
||||
auras2remove.push_back(i->second->GetId());
|
||||
@@ -6530,7 +6530,7 @@ void Player::DuelComplete(DuelCompleteType type)
|
||||
|
||||
auras2remove.clear();
|
||||
AuraMap const& auras = GetAuras();
|
||||
for (AuraMap::const_iterator i = auras.begin(); i != auras.end(); i++)
|
||||
for (AuraMap::const_iterator i = auras.begin(); i != auras.end(); ++i)
|
||||
{
|
||||
if (!i->second->IsPositive() && i->second->GetCasterGUID() == duel->opponent->GetGUID() && i->second->GetAuraApplyTime() >= duel->startTime)
|
||||
auras2remove.push_back(i->second->GetId());
|
||||
@@ -15072,13 +15072,13 @@ void Player::SendRaidInfo()
|
||||
|
||||
uint32 counter = 0, i;
|
||||
for(i = 0; i < TOTAL_DIFFICULTIES; i++)
|
||||
for (BoundInstancesMap::iterator itr = m_boundInstances[i].begin(); itr != m_boundInstances[i].end(); itr++)
|
||||
for (BoundInstancesMap::iterator itr = m_boundInstances[i].begin(); itr != m_boundInstances[i].end(); ++itr)
|
||||
if(itr->second.perm) counter++;
|
||||
|
||||
data << counter;
|
||||
for(i = 0; i < TOTAL_DIFFICULTIES; i++)
|
||||
{
|
||||
for (BoundInstancesMap::iterator itr = m_boundInstances[i].begin(); itr != m_boundInstances[i].end(); itr++)
|
||||
for (BoundInstancesMap::iterator itr = m_boundInstances[i].begin(); itr != m_boundInstances[i].end(); ++itr)
|
||||
{
|
||||
if(itr->second.perm)
|
||||
{
|
||||
@@ -15597,7 +15597,7 @@ void Player::_SaveMail()
|
||||
if (!m_mailsLoaded)
|
||||
return;
|
||||
|
||||
for (PlayerMails::iterator itr = m_mail.begin(); itr != m_mail.end(); itr++)
|
||||
for (PlayerMails::iterator itr = m_mail.begin(); itr != m_mail.end(); ++itr)
|
||||
{
|
||||
Mail *m = (*itr);
|
||||
if (m->state == MAIL_STATE_CHANGED)
|
||||
@@ -16277,7 +16277,7 @@ void Player::PetSpellInitialize()
|
||||
|
||||
if(pet->isControlled() && (pet->getPetType() == HUNTER_PET || cinfo && cinfo->type == CREATURE_TYPE_DEMON && getClass() == CLASS_WARLOCK))
|
||||
{
|
||||
for(PetSpellMap::iterator itr = pet->m_spells.begin();itr != pet->m_spells.end();itr++)
|
||||
for(PetSpellMap::iterator itr = pet->m_spells.begin();itr != pet->m_spells.end();++itr)
|
||||
{
|
||||
if(itr->second->state == PETSPELL_REMOVED)
|
||||
continue;
|
||||
|
||||
Reference in New Issue
Block a user