MCPcopy Create free account
hub / github.com/ddnet/ddnet / CurrentCommunitiesHash

Method CurrentCommunitiesHash

src/engine/client/serverbrowser.cpp:1834–1843  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1832}
1833
1834unsigned CServerBrowser::CurrentCommunitiesHash() const
1835{
1836 std::vector<const CCommunity *> vpCommunities = CurrentCommunities();
1837 unsigned Hash = 5381;
1838 for(const CCommunity *pCommunity : CurrentCommunities())
1839 {
1840 Hash = (Hash << 5) + Hash + str_quickhash(pCommunity->Id());
1841 }
1842 return Hash;
1843}
1844
1845void CCommunityCache::Update(bool Force)
1846{

Callers 1

UpdateMethod · 0.80

Calls 2

str_quickhashFunction · 0.85
IdMethod · 0.45

Tested by

no test coverage detected