MCPcopy Create free account
hub / github.com/WolfireGames/overgrowth / GetCampaigns

Method GetCampaigns

Source/Internal/modloading.cpp:2374–2386  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

2372}
2373
2374std::vector<ModInstance::Campaign> ModLoading::GetCampaigns() {
2375 std::vector<ModInstance::Campaign> campaigns;
2376 for (auto& mod : mods) {
2377 if (mod->IsActive()) {
2378 for (uint32_t j = 0; j < mod->campaigns.size(); j++) {
2379 if (strlen(mod->campaigns[j].title) > 0) {
2380 campaigns.push_back(mod->campaigns[j]);
2381 }
2382 }
2383 }
2384 }
2385 return campaigns;
2386}
2387
2388std::vector<ModInstance*> ModLoading::GetModsMatchingID(std::string id) {
2389 std::vector<ModInstance*> lmods;

Callers 3

DrawSettingsImGuiFunction · 0.80
OpenLevelMenuFunction · 0.80
ASGetCampaignsFunction · 0.80

Calls 3

IsActiveMethod · 0.45
sizeMethod · 0.45
push_backMethod · 0.45

Tested by

no test coverage detected