summaryrefslogtreecommitdiffstats
path: root/src/Root.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/Root.cpp')
-rw-r--r--src/Root.cpp13
1 files changed, 11 insertions, 2 deletions
diff --git a/src/Root.cpp b/src/Root.cpp
index b60f6ae3a..54e65b6da 100644
--- a/src/Root.cpp
+++ b/src/Root.cpp
@@ -560,14 +560,23 @@ void cRoot::SaveAllChunks(void)
void cRoot::SendPlayerLists(cPlayer * a_DestPlayer)
{
- for (WorldMap::iterator itr = m_WorldsByName.begin(), end = m_WorldsByName.end(); itr != end; ++itr)
+ for (const auto & itr : m_WorldsByName)
{
- itr->second->SendPlayerList(a_DestPlayer);
+ itr.second->SendPlayerList(a_DestPlayer);
} // for itr - m_WorldsByName[]
}
+void cRoot::BroadcastPlayerListsAddPlayer(const cPlayer & a_Player, const cClientHandle * a_Exclude)
+{
+ for (const auto & itr : m_WorldsByName)
+ {
+ itr.second->BroadcastPlayerListAddPlayer(a_Player);
+ } // for itr - m_WorldsByName[]
+}
+
+
void cRoot::BroadcastChat(const AString & a_Message, eMessageType a_ChatPrefix)
{
for (WorldMap::iterator itr = m_WorldsByName.begin(), end = m_WorldsByName.end(); itr != end; ++itr)