refactor(Core/Logging): switch to fmt style for LOG_ (#10366)

* feat(Core/Common): add support fmt style for ASSERT and ABORT

* correct CheckCompactArrayMaskOverflow

* 1

* Update src/server/game/Spells/Spell.cpp

* rework logging

* add fmt replace logs

* logging

* FMT_LOG_

* settings

* fix startup

* 1

* 2

* 3

* 4

* 5

* fmt::print

* to fmt
This commit is contained in:
Kargatum
2022-01-27 22:44:41 +07:00
committed by GitHub
parent 5228d29379
commit 5969df4e30
211 changed files with 3689 additions and 3842 deletions

View File

@@ -109,7 +109,7 @@ void Channel::UpdateChannelInDB() const
stmt->setUInt32(2, _channelDBId);
CharacterDatabase.Execute(stmt);
LOG_DEBUG("chat.system", "Channel(%s) updated in database", _name.c_str());
LOG_DEBUG("chat.system", "Channel({}) updated in database", _name);
}
}
@@ -522,9 +522,9 @@ void Channel::UnBan(Player const* player, std::string const& badname)
}
if (_channelRights.flags & CHANNEL_RIGHT_CANT_BAN)
LOG_GM(player->GetSession()->GetAccountId(), "Command: /unban %s %s (Moderator %s [%s, account: %u] unbanned %s [%s])",
GetName().c_str(), badname.c_str(), player->GetName().c_str(), player->GetGUID().ToString().c_str(), player->GetSession()->GetAccountId(),
badname.c_str(), victim.ToString().c_str());
LOG_GM(player->GetSession()->GetAccountId(), "Command: /unban {} {} (Moderator {} [{}, account: {}] unbanned {} [{}])",
GetName(), badname, player->GetName(), player->GetGUID().ToString(), player->GetSession()->GetAccountId(),
badname, victim.ToString());
bannedStore.erase(victim);
RemoveChannelBanFromDB(victim);
@@ -710,7 +710,7 @@ void Channel::List(Player const* player)
return;
}
LOG_DEBUG("chat.system", "SMSG_CHANNEL_LIST %s Channel: %s", player->GetSession()->GetPlayerInfo().c_str(), GetName().c_str());
LOG_DEBUG("chat.system", "SMSG_CHANNEL_LIST {} Channel: {}", player->GetSession()->GetPlayerInfo(), GetName());
WorldPacket data(SMSG_CHANNEL_LIST, 1 + (GetName().size() + 1) + 1 + 4 + playersStore.size() * (8 + 1));
data << uint8(1); // channel type?
data << GetName(); // channel name