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

Method Campaign_Load

Source/Fodder.cpp:1876–1894  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1874}
1875
1876bool cFodder::Campaign_Load(std::string pName) {
1877
1878 // If no campaign name was provided, use the default for the current version
1879 if (!pName.size()) {
1880
1881 if (!mVersionCurrent->isCustom()) {
1882 pName = mVersionCurrent->mName;
1883 }
1884 }
1885
1886 VersionSwitch(mVersions->GetForCampaign(pName, mParams->mDefaultPlatform));
1887 if (!mGame_Data.mCampaign.LoadCampaign(pName, pName != mVersionCurrent->mName)) {
1888 // TODO: But what?
1889
1890 return false;
1891 }
1892
1893 return true;
1894}
1895
1896void cFodder::Map_Create(sMapParams pParams) {
1897

Callers 1

StartMethod · 0.80

Calls 4

GetForCampaignMethod · 0.80
LoadCampaignMethod · 0.80
sizeMethod · 0.45
isCustomMethod · 0.45

Tested by 1

StartMethod · 0.64