summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/World.cpp2
-rw-r--r--src/World.h3
2 files changed, 3 insertions, 2 deletions
diff --git a/src/World.cpp b/src/World.cpp
index 0dec0bd96..84d40d53b 100644
--- a/src/World.cpp
+++ b/src/World.cpp
@@ -2678,7 +2678,7 @@ bool cWorld::ForEachPlayer(cPlayerListCallback & a_Callback)
bool cWorld::DoWithPlayer(const AString & a_PlayerName, cPlayerListCallback & a_Callback)
{
- // Calls the callback for each player in the list
+ // Calls the callback for the specified player in the list
cCSLock Lock(m_CSPlayers);
for (cPlayerList::iterator itr = m_Players.begin(); itr != m_Players.end(); ++itr)
{
diff --git a/src/World.h b/src/World.h
index 68d0654ee..31bc9dad6 100644
--- a/src/World.h
+++ b/src/World.h
@@ -315,7 +315,8 @@ public:
/** Calls the callback for each player in the list; returns true if all players processed, false if the callback aborted by returning true */
virtual bool ForEachPlayer(cPlayerListCallback & a_Callback) override; // >> EXPORTED IN MANUALBINDINGS <<
- /** Calls the callback for the player of the given name; returns true if the player was found and the callback called, false if player not found. Callback return ignored */
+ /** Calls the callback for the player of the given name; returns true if the player was found and the callback called, false if player not found.
+ Callback return value is ignored. If there are multiple players of the same name, only (random) one is processed by the callback. */
bool DoWithPlayer(const AString & a_PlayerName, cPlayerListCallback & a_Callback); // >> EXPORTED IN MANUALBINDINGS <<
/** Finds a player from a partial or complete player name and calls the callback - case-insensitive */