Merge branch 'azerothcore:master' into Playerbot

This commit is contained in:
ZhengPeiRu21
2023-04-24 09:38:43 -06:00
committed by GitHub
27 changed files with 7015 additions and 27 deletions

View File

@@ -1801,7 +1801,7 @@ public:
{
Unit::SetPvP(state);
if (!m_Controlled.empty())
for (auto itr : m_Controlled)
for (auto& itr : m_Controlled)
itr->SetPvP(state);
}
void UpdatePvP(bool state, bool _override = false);

View File

@@ -48,7 +48,7 @@ void Player::_LoadCharacterSettings(PreparedQueryResult result)
uint32 count = 0;
for (auto token : tokens)
for (auto& token : tokens)
{
if (token.empty())
{
@@ -95,11 +95,11 @@ void Player::_SavePlayerSettings(CharacterDatabaseTransaction trans)
return;
}
for (auto itr : m_charSettingsMap)
for (auto& itr : m_charSettingsMap)
{
std::ostringstream data;
for (auto setting : itr.second)
for (auto& setting : itr.second)
{
data << setting.value << ' ';
}