[7313] Optimized checks of presence in std::set Author: zhenya

--HG--
branch : trunk
This commit is contained in:
megamage
2009-02-21 17:03:39 -06:00
parent 3fb55c922f
commit 4ecbdb128c
5 changed files with 15 additions and 10 deletions
+2 -5
View File
@@ -204,11 +204,8 @@ class Channel
void SendToAllButOne(WorldPacket *data, uint64 who);
void SendToOne(WorldPacket *data, uint64 who);
bool IsOn(uint64 who) const { return players.count(who) != 0; }
bool IsBanned(const uint64 guid) const {return banned.count(guid) != 0; }
bool IsFirst() const { return !(players.size() > 1); }
bool IsOn(uint64 who) const { return players.find(who) != players.end(); }
bool IsBanned(uint64 guid) const { return banned.find(guid) != banned.end(); }
uint8 GetPlayerFlags(uint64 p) const
{