diff options
author | Andrei Karas <akaras@inbox.ru> | 2013-01-19 15:25:24 +0300 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2013-01-20 17:05:57 +0300 |
commit | 48071e171de41a23197c7328ba038331a936e0eb (patch) | |
tree | 73c7ef1da8e5dd76469d75c0336d88c3371e4263 /src/localplayer.cpp | |
parent | d07fba228b5251862ad670e1d4f079c9456fab4b (diff) | |
download | manaverse-48071e171de41a23197c7328ba038331a936e0eb.tar.gz manaverse-48071e171de41a23197c7328ba038331a936e0eb.tar.bz2 manaverse-48071e171de41a23197c7328ba038331a936e0eb.tar.xz manaverse-48071e171de41a23197c7328ba038331a936e0eb.zip |
Replace for to FOR_EACH in some classes.
Diffstat (limited to 'src/localplayer.cpp')
-rw-r--r-- | src/localplayer.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/localplayer.cpp b/src/localplayer.cpp index 7fc7d725c..0a571b3f2 100644 --- a/src/localplayer.cpp +++ b/src/localplayer.cpp @@ -75,6 +75,8 @@ const short awayLimitTimer = 60; +typedef std::map<int, Guild*>::const_iterator GuildMapCIter; + LocalPlayer *player_node = nullptr; extern std::list<BeingCacheEntry*> beingInfoCache; @@ -903,8 +905,7 @@ void LocalPlayer::inviteToGuild(Being *const being) // TODO: Allow user to choose which guild to invite being to // For now, just invite to the first guild you have permissions to invite with - for (std::map<int, Guild*>::const_iterator itr = mGuilds.begin(), - itr_end = mGuilds.end(); itr != itr_end; ++itr) + FOR_EACH (GuildMapCIter, itr, mGuilds) { if (itr->second && checkInviteRights(itr->second->getName())) { |