[svn] Fixed a crash in OutdoorPvP*::BuffTeam().
--HG-- branch : trunk
This commit is contained in:
@@ -840,9 +840,9 @@ void OutdoorPvPEP::BuffTeams()
|
||||
if(Player * plr = objmgr.GetPlayer(*itr))
|
||||
{
|
||||
for(int i = 0; i < 4; ++i)
|
||||
plr->RemoveAurasDueToSpell(EP_AllianceBuffs[i]);
|
||||
if(plr->IsInWorld()) plr->RemoveAurasDueToSpell(EP_AllianceBuffs[i]);
|
||||
if(m_AllianceTowersControlled && m_AllianceTowersControlled < 5)
|
||||
plr->CastSpell(plr,EP_AllianceBuffs[m_AllianceTowersControlled-1],true);
|
||||
if(plr->IsInWorld()) plr->CastSpell(plr,EP_AllianceBuffs[m_AllianceTowersControlled-1],true);
|
||||
}
|
||||
}
|
||||
for(std::set<uint64>::iterator itr = m_PlayerGuids[1].begin(); itr != m_PlayerGuids[1].end(); ++itr)
|
||||
@@ -850,9 +850,9 @@ void OutdoorPvPEP::BuffTeams()
|
||||
if(Player * plr = objmgr.GetPlayer(*itr))
|
||||
{
|
||||
for(int i = 0; i < 4; ++i)
|
||||
plr->RemoveAurasDueToSpell(EP_HordeBuffs[i]);
|
||||
if(plr->IsInWorld()) plr->RemoveAurasDueToSpell(EP_HordeBuffs[i]);
|
||||
if(m_HordeTowersControlled && m_HordeTowersControlled < 5)
|
||||
plr->CastSpell(plr,EP_HordeBuffs[m_HordeTowersControlled-1],true);
|
||||
if(plr->IsInWorld()) plr->CastSpell(plr,EP_HordeBuffs[m_HordeTowersControlled-1],true);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user