chore(core): cleanup code p3 (#16073)

* Update MMapMgr.cpp

* Update UpdateFetcher.cpp

* Update AuctionHouseMgr.cpp

* Update AuctionHouseMgr.h

* Update BattlegroundAV.cpp

* Update ChannelMgr.cpp

* Update ThreatMgr.h

* Update Player.h

* Update PlayerSettings.cpp

* Update ObjectMgr.cpp

* Update Guild.cpp

* Update Guild.h

* Update Map.cpp

* Update World.cpp

* Update boss_nefarian.cpp

* Update boss_prince_malchezaar.cpp

* Update boss_venoxis.cpp

* Update zone_elwynn_forest.cpp

* Update zulfarrak.cpp

* Update boss_novos.cpp
This commit is contained in:
天鹿
2023-04-24 19:13:07 +08:00
committed by GitHub
parent 5dc6f9cf78
commit df77b5f4f7
20 changed files with 26 additions and 26 deletions

View File

@@ -1243,7 +1243,7 @@ class spell_shadowblink : public SpellScript
return;
}
for (auto itr : spellPos)
for (auto& itr : spellPos)
{
float distTarget = target->GetDistance2d(itr.second.m_positionX, itr.second.m_positionY);
if (distTarget <= 30.f)

View File

@@ -248,7 +248,7 @@ struct boss_malchezaar : public BossAI
void EnfeebleResetHealth()
{
for (auto targets : _enfeebleTargets)
for (auto& targets : _enfeebleTargets)
{
if (Unit* target = ObjectAccessor::GetUnit(*me, targets.first))
{

View File

@@ -131,7 +131,7 @@ public:
if (!cobraList.empty())
{
for (auto cobras : cobraList)
for (auto& cobras : cobraList)
{
cobras->SetInCombatWithZone();
}

View File

@@ -101,7 +101,7 @@ struct npc_cameron : public ScriptedAI
Acore::Containers::RandomShuffle(MovePosPositions);
// first we break formation because children will need to move on their own now
for (auto guid : _childrenGUIDs)
for (auto& guid : _childrenGUIDs)
if (Creature* child = ObjectAccessor::GetCreature(*me, guid))
if (child->GetFormation())
child->GetFormation()->RemoveMember(child);
@@ -228,7 +228,7 @@ struct npc_cameron : public ScriptedAI
// If Formation was disbanded, remake.
if (!me->GetFormation()->IsFormed())
for (auto guid : _childrenGUIDs)
for (auto& guid : _childrenGUIDs)
if (Creature* child = ObjectAccessor::GetCreature(*me, guid))
child->SearchFormation();