mirror of
https://github.com/TrinityCore/TrinityCore.git
synced 2026-01-31 06:07:37 +01:00
Merge branch 'master' of https://github.com/TrinityCore/TrinityCore into 4.3.4
Conflicts: src/server/game/Achievements/AchievementMgr.cpp src/server/game/Battlefield/Battlefield.h src/server/game/Battlegrounds/ArenaScore.h src/server/game/Battlegrounds/ArenaTeam.cpp src/server/game/Battlegrounds/ArenaTeam.h src/server/game/Battlegrounds/ArenaTeamMgr.cpp src/server/game/Battlegrounds/BattlegroundMgr.cpp src/server/game/Battlegrounds/BattlegroundMgr.h src/server/game/Battlegrounds/BattlegroundQueue.h src/server/game/Battlegrounds/BattlegroundScore.h src/server/game/Battlegrounds/Zones/BattlegroundAB.h src/server/game/Battlegrounds/Zones/BattlegroundAV.h src/server/game/Battlegrounds/Zones/BattlegroundEY.h src/server/game/Battlegrounds/Zones/BattlegroundIC.h src/server/game/Battlegrounds/Zones/BattlegroundSA.h src/server/game/Battlegrounds/Zones/BattlegroundWS.h src/server/game/DungeonFinding/LFG.h src/server/game/DungeonFinding/LFGMgr.cpp src/server/game/DungeonFinding/LFGMgr.h src/server/game/DungeonFinding/LFGQueue.cpp src/server/game/DungeonFinding/LFGQueue.h src/server/game/Entities/Corpse/Corpse.cpp src/server/game/Entities/Creature/Creature.cpp src/server/game/Entities/Creature/GossipDef.cpp src/server/game/Entities/Creature/GossipDef.h src/server/game/Entities/Creature/TemporarySummon.cpp src/server/game/Entities/DynamicObject/DynamicObject.cpp src/server/game/Entities/Object/Object.cpp src/server/game/Entities/Object/Object.h src/server/game/Entities/Object/ObjectDefines.h src/server/game/Entities/Object/Updates/UpdateData.cpp src/server/game/Entities/Player/Player.cpp src/server/game/Entities/Player/Player.h src/server/game/Entities/Unit/Unit.cpp src/server/game/Entities/Unit/Unit.h src/server/game/Globals/ObjectAccessor.cpp src/server/game/Globals/ObjectAccessor.h src/server/game/Globals/ObjectMgr.cpp src/server/game/Groups/Group.cpp src/server/game/Groups/Group.h src/server/game/Guilds/Guild.cpp src/server/game/Guilds/Guild.h src/server/game/Handlers/AuctionHouseHandler.cpp src/server/game/Handlers/BattleGroundHandler.cpp src/server/game/Handlers/CalendarHandler.cpp src/server/game/Handlers/CharacterHandler.cpp src/server/game/Handlers/ChatHandler.cpp src/server/game/Handlers/GroupHandler.cpp src/server/game/Handlers/GuildHandler.cpp src/server/game/Handlers/ItemHandler.cpp src/server/game/Handlers/LFGHandler.cpp src/server/game/Handlers/MailHandler.cpp src/server/game/Handlers/MiscHandler.cpp src/server/game/Handlers/MovementHandler.cpp src/server/game/Handlers/NPCHandler.cpp src/server/game/Handlers/PetHandler.cpp src/server/game/Handlers/QueryHandler.cpp src/server/game/Handlers/QuestHandler.cpp src/server/game/Handlers/TradeHandler.cpp src/server/game/Handlers/VehicleHandler.cpp src/server/game/Movement/Spline/MoveSplineInit.cpp src/server/game/Server/WorldSession.cpp src/server/game/Server/WorldSession.h src/server/game/Spells/Spell.cpp src/server/scripts/Commands/cs_debug.cpp src/server/scripts/Commands/cs_gm.cpp src/server/scripts/Commands/cs_misc.cpp src/server/scripts/Commands/cs_modify.cpp src/server/scripts/Commands/cs_reset.cpp src/server/scripts/EasternKingdoms/ZulAman/boss_akilzon.cpp src/server/scripts/EasternKingdoms/ZulAman/boss_halazzi.cpp src/server/scripts/EasternKingdoms/ZulAman/boss_hexlord.cpp src/server/scripts/EasternKingdoms/ZulAman/boss_janalai.cpp src/server/scripts/EasternKingdoms/ZulAman/boss_zuljin.cpp src/server/scripts/EasternKingdoms/ZulAman/instance_zulaman.cpp src/server/scripts/EasternKingdoms/ZulAman/zulaman.cpp src/server/scripts/EasternKingdoms/ZulGurub/boss_arlokk.cpp src/server/scripts/EasternKingdoms/ZulGurub/boss_jindo.cpp src/server/scripts/EasternKingdoms/ZulGurub/boss_mandokir.cpp src/server/scripts/EasternKingdoms/ZulGurub/boss_thekal.cpp src/server/scripts/EasternKingdoms/ZulGurub/instance_zulgurub.cpp src/server/scripts/EasternKingdoms/zone_silverpine_forest.cpp src/server/scripts/EasternKingdoms/zone_stormwind_city.cpp src/server/scripts/EasternKingdoms/zone_swamp_of_sorrows.cpp src/server/scripts/EasternKingdoms/zone_tirisfal_glades.cpp src/server/scripts/Kalimdor/zone_azshara.cpp src/server/scripts/Kalimdor/zone_durotar.cpp src/server/scripts/Kalimdor/zone_moonglade.cpp src/server/scripts/Kalimdor/zone_orgrimmar.cpp src/server/scripts/Kalimdor/zone_ungoro_crater.cpp src/server/scripts/Northrend/FrozenHalls/HallsOfReflection/halls_of_reflection.cpp src/server/scripts/Northrend/IcecrownCitadel/boss_the_lich_king.cpp src/server/scripts/Northrend/Naxxramas/boss_kelthuzad.cpp src/server/scripts/OutdoorPvP/OutdoorPvPEP.cpp src/server/scripts/Spells/spell_dk.cpp src/server/scripts/Spells/spell_generic.cpp src/server/shared/Packets/ByteBuffer.h
This commit is contained in:
@@ -36,20 +36,20 @@ namespace lfg
|
||||
@param[in] check list of guids
|
||||
@returns Concatenated string
|
||||
*/
|
||||
std::string ConcatenateGuids(LfgGuidList const& check)
|
||||
std::string ConcatenateGuids(GuidList const& check)
|
||||
{
|
||||
if (check.empty())
|
||||
return "";
|
||||
|
||||
// need the guids in order to avoid duplicates
|
||||
LfgGuidSet guids(check.begin(), check.end());
|
||||
GuidSet guids(check.begin(), check.end());
|
||||
|
||||
std::ostringstream o;
|
||||
|
||||
LfgGuidSet::const_iterator it = guids.begin();
|
||||
o << (*it);
|
||||
GuidSet::const_iterator it = guids.begin();
|
||||
o << it->GetRawValue();
|
||||
for (++it; it != guids.end(); ++it)
|
||||
o << '|' << (*it);
|
||||
o << '|' << it->GetRawValue();
|
||||
|
||||
return o.str();
|
||||
}
|
||||
@@ -83,26 +83,26 @@ char const* GetCompatibleString(LfgCompatibility compatibles)
|
||||
}
|
||||
}
|
||||
|
||||
void LFGQueue::AddToQueue(uint64 guid)
|
||||
void LFGQueue::AddToQueue(ObjectGuid guid)
|
||||
{
|
||||
LfgQueueDataContainer::iterator itQueue = QueueDataStore.find(guid);
|
||||
if (itQueue == QueueDataStore.end())
|
||||
{
|
||||
TC_LOG_ERROR("lfg.queue.add", "Queue data not found for [" UI64FMTD "]", guid);
|
||||
TC_LOG_ERROR("lfg.queue.add", "Queue data not found for [%s]", guid.ToString().c_str());
|
||||
return;
|
||||
}
|
||||
|
||||
AddToNewQueue(guid);
|
||||
}
|
||||
|
||||
void LFGQueue::RemoveFromQueue(uint64 guid)
|
||||
void LFGQueue::RemoveFromQueue(ObjectGuid guid)
|
||||
{
|
||||
RemoveFromNewQueue(guid);
|
||||
RemoveFromCurrentQueue(guid);
|
||||
RemoveFromCompatibles(guid);
|
||||
|
||||
std::ostringstream o;
|
||||
o << guid;
|
||||
o << guid.GetRawValue();
|
||||
std::string sguid = o.str();
|
||||
|
||||
LfgQueueDataContainer::iterator itDelete = QueueDataStore.end();
|
||||
@@ -122,33 +122,33 @@ void LFGQueue::RemoveFromQueue(uint64 guid)
|
||||
QueueDataStore.erase(itDelete);
|
||||
}
|
||||
|
||||
void LFGQueue::AddToNewQueue(uint64 guid)
|
||||
void LFGQueue::AddToNewQueue(ObjectGuid guid)
|
||||
{
|
||||
newToQueueStore.push_back(guid);
|
||||
}
|
||||
|
||||
void LFGQueue::RemoveFromNewQueue(uint64 guid)
|
||||
void LFGQueue::RemoveFromNewQueue(ObjectGuid guid)
|
||||
{
|
||||
newToQueueStore.remove(guid);
|
||||
}
|
||||
|
||||
void LFGQueue::AddToCurrentQueue(uint64 guid)
|
||||
void LFGQueue::AddToCurrentQueue(ObjectGuid guid)
|
||||
{
|
||||
currentQueueStore.push_back(guid);
|
||||
}
|
||||
|
||||
void LFGQueue::RemoveFromCurrentQueue(uint64 guid)
|
||||
void LFGQueue::RemoveFromCurrentQueue(ObjectGuid guid)
|
||||
{
|
||||
currentQueueStore.remove(guid);
|
||||
}
|
||||
|
||||
void LFGQueue::AddQueueData(uint64 guid, time_t joinTime, LfgDungeonSet const& dungeons, LfgRolesMap const& rolesMap)
|
||||
void LFGQueue::AddQueueData(ObjectGuid guid, time_t joinTime, LfgDungeonSet const& dungeons, LfgRolesMap const& rolesMap)
|
||||
{
|
||||
QueueDataStore[guid] = LfgQueueData(joinTime, dungeons, rolesMap);
|
||||
AddToQueue(guid);
|
||||
}
|
||||
|
||||
void LFGQueue::RemoveQueueData(uint64 guid)
|
||||
void LFGQueue::RemoveQueueData(ObjectGuid guid)
|
||||
{
|
||||
LfgQueueDataContainer::iterator it = QueueDataStore.find(guid);
|
||||
if (it != QueueDataStore.end())
|
||||
@@ -188,13 +188,13 @@ void LFGQueue::UpdateWaitTimeDps(int32 waitTime, uint32 dungeonId)
|
||||
|
||||
@param[in] guid Guid to remove from compatible cache
|
||||
*/
|
||||
void LFGQueue::RemoveFromCompatibles(uint64 guid)
|
||||
void LFGQueue::RemoveFromCompatibles(ObjectGuid guid)
|
||||
{
|
||||
std::stringstream out;
|
||||
out << guid;
|
||||
out << guid.GetRawValue();
|
||||
std::string strGuid = out.str();
|
||||
|
||||
TC_LOG_DEBUG("lfg.queue.data.compatibles.remove", "Removing [" UI64FMTD "]", guid);
|
||||
TC_LOG_DEBUG("lfg.queue.data.compatibles.remove", "Removing %s", guid.ToString().c_str());
|
||||
for (LfgCompatibleContainer::iterator itNext = CompatibleMapStore.begin(); itNext != CompatibleMapStore.end();)
|
||||
{
|
||||
LfgCompatibleContainer::iterator it = itNext++;
|
||||
@@ -247,16 +247,18 @@ LfgCompatibilityData* LFGQueue::GetCompatibilityData(std::string const& key)
|
||||
uint8 LFGQueue::FindGroups()
|
||||
{
|
||||
uint8 proposals = 0;
|
||||
LfgGuidList firstNew;
|
||||
GuidList firstNew;
|
||||
while (!newToQueueStore.empty())
|
||||
{
|
||||
uint64 frontguid = newToQueueStore.front();
|
||||
TC_LOG_DEBUG("lfg.queue.match.check.new", "Checking [" UI64FMTD "] newToQueue(%u), currentQueue(%u)", frontguid, uint32(newToQueueStore.size()), uint32(currentQueueStore.size()));
|
||||
ObjectGuid frontguid = newToQueueStore.front();
|
||||
TC_LOG_DEBUG("lfg.queue.match.check.new", "Checking [%s] newToQueue(%u), currentQueue(%u)", frontguid.ToString().c_str(),
|
||||
uint32(newToQueueStore.size()), uint32(currentQueueStore.size()));
|
||||
|
||||
firstNew.clear();
|
||||
firstNew.push_back(frontguid);
|
||||
RemoveFromNewQueue(frontguid);
|
||||
|
||||
LfgGuidList temporalList = currentQueueStore;
|
||||
GuidList temporalList = currentQueueStore;
|
||||
LfgCompatibility compatibles = FindNewGroups(firstNew, temporalList);
|
||||
|
||||
if (compatibles == LFG_COMPATIBLES_MATCH)
|
||||
@@ -274,7 +276,7 @@ uint8 LFGQueue::FindGroups()
|
||||
@param[in] all List of all other guids in main queue to match against
|
||||
@return LfgCompatibility type of compatibility between groups
|
||||
*/
|
||||
LfgCompatibility LFGQueue::FindNewGroups(LfgGuidList& check, LfgGuidList& all)
|
||||
LfgCompatibility LFGQueue::FindNewGroups(GuidList& check, GuidList& all)
|
||||
{
|
||||
std::string strGuids = ConcatenateGuids(check);
|
||||
LfgCompatibility compatibles = GetCompatibles(strGuids);
|
||||
@@ -312,7 +314,7 @@ LfgCompatibility LFGQueue::FindNewGroups(LfgGuidList& check, LfgGuidList& all)
|
||||
@param[in] check List of guids to check compatibilities
|
||||
@return LfgCompatibility type of compatibility
|
||||
*/
|
||||
LfgCompatibility LFGQueue::CheckCompatibility(LfgGuidList check)
|
||||
LfgCompatibility LFGQueue::CheckCompatibility(GuidList check)
|
||||
{
|
||||
std::string strGuids = ConcatenateGuids(check);
|
||||
LfgProposal proposal;
|
||||
@@ -330,7 +332,7 @@ LfgCompatibility LFGQueue::CheckCompatibility(LfgGuidList check)
|
||||
// Check all-but-new compatiblitity
|
||||
if (check.size() > 2)
|
||||
{
|
||||
uint64 frontGuid = check.front();
|
||||
ObjectGuid frontGuid = check.front();
|
||||
check.pop_front();
|
||||
|
||||
// Check all-but-new compatibilities (New, A, B, C, D) --> check(A, B, C, D)
|
||||
@@ -347,20 +349,20 @@ LfgCompatibility LFGQueue::CheckCompatibility(LfgGuidList check)
|
||||
// Check if more than one LFG group and number of players joining
|
||||
uint8 numPlayers = 0;
|
||||
uint8 numLfgGroups = 0;
|
||||
for (LfgGuidList::const_iterator it = check.begin(); it != check.end() && numLfgGroups < 2 && numPlayers <= MAXGROUPSIZE; ++it)
|
||||
for (GuidList::const_iterator it = check.begin(); it != check.end() && numLfgGroups < 2 && numPlayers <= MAXGROUPSIZE; ++it)
|
||||
{
|
||||
uint64 guid = (*it);
|
||||
ObjectGuid guid = *it;
|
||||
LfgQueueDataContainer::iterator itQueue = QueueDataStore.find(guid);
|
||||
if (itQueue == QueueDataStore.end())
|
||||
{
|
||||
TC_LOG_ERROR("lfg.queue.match.compatibility.check", "Guid: [" UI64FMTD "] is not queued but listed as queued!", guid);
|
||||
TC_LOG_ERROR("lfg.queue.match.compatibility.check", "Guid: [%s] is not queued but listed as queued!", guid.ToString().c_str());
|
||||
RemoveFromQueue(guid);
|
||||
return LFG_COMPATIBILITY_PENDING;
|
||||
}
|
||||
|
||||
// Store group so we don't need to call Mgr to get it later (if it's player group will be 0 otherwise would have joined as group)
|
||||
for (LfgRolesMap::const_iterator it2 = itQueue->second.roles.begin(); it2 != itQueue->second.roles.end(); ++it2)
|
||||
proposalGroups[it2->first] = IS_GROUP_GUID(itQueue->first) ? itQueue->first : 0;
|
||||
proposalGroups[it2->first] = itQueue->first.IsGroup() ? itQueue->first : ObjectGuid::Empty;
|
||||
|
||||
numPlayers += itQueue->second.roles.size();
|
||||
|
||||
@@ -404,16 +406,16 @@ LfgCompatibility LFGQueue::CheckCompatibility(LfgGuidList check)
|
||||
// If it's single group no need to check for duplicate players, ignores, bad roles or bad dungeons as it's been checked before joining
|
||||
if (check.size() > 1)
|
||||
{
|
||||
for (LfgGuidList::const_iterator it = check.begin(); it != check.end(); ++it)
|
||||
for (GuidList::const_iterator it = check.begin(); it != check.end(); ++it)
|
||||
{
|
||||
const LfgRolesMap &roles = QueueDataStore[(*it)].roles;
|
||||
LfgRolesMap const& roles = QueueDataStore[(*it)].roles;
|
||||
for (LfgRolesMap::const_iterator itRoles = roles.begin(); itRoles != roles.end(); ++itRoles)
|
||||
{
|
||||
LfgRolesMap::const_iterator itPlayer;
|
||||
for (itPlayer = proposalRoles.begin(); itPlayer != proposalRoles.end(); ++itPlayer)
|
||||
{
|
||||
if (itRoles->first == itPlayer->first)
|
||||
TC_LOG_ERROR("lfg.queue.match.compatibility.check", "Guids: ERROR! Player multiple times in queue! [" UI64FMTD "]", itRoles->first);
|
||||
TC_LOG_ERROR("lfg.queue.match.compatibility.check", "Guids: ERROR! Player multiple times in queue! [%s]", itRoles->first.ToString().c_str());
|
||||
else if (sLFGMgr->HasIgnore(itRoles->first, itPlayer->first))
|
||||
break;
|
||||
}
|
||||
@@ -434,22 +436,22 @@ LfgCompatibility LFGQueue::CheckCompatibility(LfgGuidList check)
|
||||
{
|
||||
std::ostringstream o;
|
||||
for (LfgRolesMap::const_iterator it = debugRoles.begin(); it != debugRoles.end(); ++it)
|
||||
o << ", " << it->first << ": " << GetRolesString(it->second);
|
||||
o << ", " << it->first.GetRawValue() << ": " << GetRolesString(it->second);
|
||||
|
||||
TC_LOG_DEBUG("lfg.queue.match.compatibility.check", "Guids: (%s) Roles not compatible%s", strGuids.c_str(), o.str().c_str());
|
||||
SetCompatibles(strGuids, LFG_INCOMPATIBLES_NO_ROLES);
|
||||
return LFG_INCOMPATIBLES_NO_ROLES;
|
||||
}
|
||||
|
||||
LfgGuidList::iterator itguid = check.begin();
|
||||
GuidList::iterator itguid = check.begin();
|
||||
proposalDungeons = QueueDataStore[*itguid].dungeons;
|
||||
std::ostringstream o;
|
||||
o << ", " << *itguid << ": (" << ConcatenateDungeons(proposalDungeons) << ")";
|
||||
o << ", " << itguid->GetRawValue() << ": (" << ConcatenateDungeons(proposalDungeons) << ")";
|
||||
for (++itguid; itguid != check.end(); ++itguid)
|
||||
{
|
||||
LfgDungeonSet temporal;
|
||||
LfgDungeonSet &dungeons = QueueDataStore[*itguid].dungeons;
|
||||
o << ", " << *itguid << ": (" << ConcatenateDungeons(dungeons) << ")";
|
||||
LfgDungeonSet& dungeons = QueueDataStore[*itguid].dungeons;
|
||||
o << ", " << itguid->GetRawValue() << ": (" << ConcatenateDungeons(dungeons) << ")";
|
||||
std::set_intersection(proposalDungeons.begin(), proposalDungeons.end(), dungeons.begin(), dungeons.end(), std::inserter(temporal, temporal.begin()));
|
||||
proposalDungeons = temporal;
|
||||
}
|
||||
@@ -463,7 +465,7 @@ LfgCompatibility LFGQueue::CheckCompatibility(LfgGuidList check)
|
||||
}
|
||||
else
|
||||
{
|
||||
uint64 gguid = *check.begin();
|
||||
ObjectGuid gguid = *check.begin();
|
||||
const LfgQueueData &queue = QueueDataStore[gguid];
|
||||
proposalDungeons = queue.dungeons;
|
||||
proposalRoles = queue.roles;
|
||||
@@ -477,14 +479,14 @@ LfgCompatibility LFGQueue::CheckCompatibility(LfgGuidList check)
|
||||
LfgCompatibilityData data(LFG_COMPATIBLES_WITH_LESS_PLAYERS);
|
||||
data.roles = proposalRoles;
|
||||
|
||||
for (LfgGuidList::const_iterator itr = check.begin(); itr != check.end(); ++itr)
|
||||
for (GuidList::const_iterator itr = check.begin(); itr != check.end(); ++itr)
|
||||
UpdateBestCompatibleInQueue(QueueDataStore.find(*itr), strGuids, data.roles);
|
||||
|
||||
SetCompatibilityData(strGuids, data);
|
||||
return LFG_COMPATIBLES_WITH_LESS_PLAYERS;
|
||||
}
|
||||
|
||||
uint64 gguid = *check.begin();
|
||||
ObjectGuid gguid = *check.begin();
|
||||
proposal.queues = check;
|
||||
proposal.isNew = numLfgGroups != 1 || sLFGMgr->GetOldState(gguid) != LFG_STATE_DUNGEON;
|
||||
|
||||
@@ -498,7 +500,7 @@ LfgCompatibility LFGQueue::CheckCompatibility(LfgGuidList check)
|
||||
// Create a new proposal
|
||||
proposal.cancelTime = time(NULL) + LFG_TIME_PROPOSAL;
|
||||
proposal.state = LFG_PROPOSAL_INITIATING;
|
||||
proposal.leader = 0;
|
||||
proposal.leader.Clear();
|
||||
proposal.dungeonId = Trinity::Containers::SelectRandomContainerElement(proposalDungeons);
|
||||
|
||||
bool leader = false;
|
||||
@@ -523,9 +525,9 @@ LfgCompatibility LFGQueue::CheckCompatibility(LfgGuidList check)
|
||||
}
|
||||
|
||||
// Mark proposal members as not queued (but not remove queue data)
|
||||
for (LfgGuidList::const_iterator itQueue = proposal.queues.begin(); itQueue != proposal.queues.end(); ++itQueue)
|
||||
for (GuidList::const_iterator itQueue = proposal.queues.begin(); itQueue != proposal.queues.end(); ++itQueue)
|
||||
{
|
||||
uint64 guid = (*itQueue);
|
||||
ObjectGuid guid = (*itQueue);
|
||||
RemoveFromNewQueue(guid);
|
||||
RemoveFromCurrentQueue(guid);
|
||||
}
|
||||
@@ -581,13 +583,13 @@ void LFGQueue::UpdateQueueTimers(uint8 queueId, time_t currTime)
|
||||
LfgQueueStatusData queueData(queueId, dungeonId, queueinfo.joinTime, waitTime, wtAvg, wtTank, wtHealer, wtDps, queuedTime, queueinfo.tanks, queueinfo.healers, queueinfo.dps);
|
||||
for (LfgRolesMap::const_iterator itPlayer = queueinfo.roles.begin(); itPlayer != queueinfo.roles.end(); ++itPlayer)
|
||||
{
|
||||
uint64 pguid = itPlayer->first;
|
||||
ObjectGuid pguid = itPlayer->first;
|
||||
LFGMgr::SendLfgQueueStatus(pguid, queueData);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
time_t LFGQueue::GetJoinTime(uint64 guid) const
|
||||
time_t LFGQueue::GetJoinTime(ObjectGuid guid) const
|
||||
{
|
||||
LfgQueueDataContainer::const_iterator itr = QueueDataStore.find(guid);
|
||||
if (itr != QueueDataStore.end())
|
||||
@@ -604,11 +606,11 @@ std::string LFGQueue::DumpQueueInfo() const
|
||||
|
||||
for (uint8 i = 0; i < 2; ++i)
|
||||
{
|
||||
LfgGuidList const& queue = i ? newToQueueStore : currentQueueStore;
|
||||
for (LfgGuidList::const_iterator it = queue.begin(); it != queue.end(); ++it)
|
||||
GuidList const& queue = i ? newToQueueStore : currentQueueStore;
|
||||
for (GuidList::const_iterator it = queue.begin(); it != queue.end(); ++it)
|
||||
{
|
||||
uint64 guid = *it;
|
||||
if (IS_GROUP_GUID(guid))
|
||||
ObjectGuid guid = *it;
|
||||
if (guid.IsGroup())
|
||||
{
|
||||
groups++;
|
||||
playersInGroup += sLFGMgr->GetPlayerCount(guid);
|
||||
@@ -635,9 +637,9 @@ std::string LFGQueue::DumpCompatibleInfo(bool full /* = false */) const
|
||||
|
||||
void LFGQueue::FindBestCompatibleInQueue(LfgQueueDataContainer::iterator itrQueue)
|
||||
{
|
||||
TC_LOG_DEBUG("lfg.queue.compatibles.find", "Guid: " UI64FMTD, itrQueue->first);
|
||||
TC_LOG_DEBUG("lfg.queue.compatibles.find", "%s", itrQueue->first.ToString().c_str());
|
||||
std::ostringstream o;
|
||||
o << itrQueue->first;
|
||||
o << itrQueue->first.GetRawValue();
|
||||
std::string sguid = o.str();
|
||||
|
||||
for (LfgCompatibleContainer::const_iterator itr = CompatibleMapStore.begin(); itr != CompatibleMapStore.end(); ++itr)
|
||||
@@ -660,8 +662,8 @@ void LFGQueue::UpdateBestCompatibleInQueue(LfgQueueDataContainer::iterator itrQu
|
||||
if (size <= storedSize)
|
||||
return;
|
||||
|
||||
TC_LOG_DEBUG("lfg.queue.compatibles.update", "Changed (%s) to (%s) as best compatible group for " UI64FMTD,
|
||||
queueData.bestCompatible.c_str(), key.c_str(), itrQueue->first);
|
||||
TC_LOG_DEBUG("lfg.queue.compatibles.update", "Changed (%s) to (%s) as best compatible group for %s",
|
||||
queueData.bestCompatible.c_str(), key.c_str(), itrQueue->first.ToString().c_str());
|
||||
|
||||
queueData.bestCompatible = key;
|
||||
queueData.tanks = LFG_TANKS_NEEDED;
|
||||
|
||||
Reference in New Issue
Block a user