MCPcopy Create free account
hub / github.com/OpenXcom/OpenXcom / getAvailableContainment

Method getAvailableContainment

src/Savegame/Base.cpp:1120–1131  ·  view source on GitHub ↗

* Returns the total amount of Containment Space * available in the base. * @return Containment Lab space. */

Source from the content-addressed store, hash-verified

1118 * @return Containment Lab space.
1119 */
1120int Base::getAvailableContainment() const
1121{
1122 int total = 0;
1123 for (std::vector<BaseFacility*>::const_iterator i = _facilities.begin(); i != _facilities.end(); ++i)
1124 {
1125 if ((*i)->getBuildTime() == 0)
1126 {
1127 total += (*i)->getRules()->getAliens();
1128 }
1129 }
1130 return total;
1131}
1132
1133/**
1134 * Returns the base's battlescape status.

Callers 7

inUseMethod · 0.80
prepareDebriefingMethod · 0.80
recoverItemsMethod · 0.80
initMethod · 0.80
updateStringsMethod · 0.80
increaseByValueMethod · 0.80

Calls 3

getAliensMethod · 0.80
getBuildTimeMethod · 0.45
getRulesMethod · 0.45

Tested by

no test coverage detected