MCPcopy Create free account
hub / github.com/OpenFodder/openfodder / getSpriteTypeCount

Method getSpriteTypeCount

Source/Map/Random.cpp:41–51  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

39}
40
41int32 cRandomMap::getSpriteTypeCount(size_t pSpriteType) {
42 int32 count = 0;
43
44 for (auto& Sprite : mSprites) {
45
46 if (Sprite.field_18 == pSpriteType)
47 ++count;
48 }
49
50 return count;
51}
52
53std::vector<sSprite*> cRandomMap::getSpritesByType(size_t pSpriteType) {
54 std::vector<sSprite*> results;

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected