MCPcopy Create free account
hub / github.com/bwapi/bwapi / stop

Method stop

bwapi/TestAIModule/Source/CancelTrainTest.cpp:242–257  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

240}
241
242void CancelTrainTest::stop()
243{
244 if (fail == true) return;
245 BWAssertF(producer!=NULL,{fail=true;return;});
246 BWAssertF(producer->isConstructing()==false,{fail=true;return;});
247 BWAssertF(producer->isIdle()==true,{fail=true;return;});
248 BWAssertF(producer->isLifted()==false,{fail=true;return;});
249 BWAssertF(producer->isTraining()==false,{fail=true;return;});
250 BWAssertF(producer->getTrainingQueue().empty()==true,{fail=true;return;});
251 BWAssertF(Broodwar->self()->minerals() == originalMineralCount,{fail=true;return;});
252 BWAssertF(Broodwar->self()->gas() == originalGasCount,{fail=true;return;});
253 BWAssertF(Broodwar->self()->supplyUsed() == originalSupplyUsedCount,{fail=true;return;});
254 BWAssertF(Broodwar->self()->allUnitCount(unitType1) == originalAllUnit1Count,{fail=true;return;});
255 BWAssertF(Broodwar->self()->allUnitCount(unitType2) == originalAllUnit2Count,{fail=true;return;});
256 BWAssertF(Broodwar->self()->allUnitCount(unitType3) == originalAllUnit3Count,{fail=true;return;});
257}

Callers

nothing calls this directly

Calls 10

isConstructingMethod · 0.80
isIdleMethod · 0.80
isLiftedMethod · 0.80
isTrainingMethod · 0.80
getTrainingQueueMethod · 0.80
mineralsMethod · 0.80
gasMethod · 0.80
supplyUsedMethod · 0.80
allUnitCountMethod · 0.80
selfMethod · 0.45

Tested by

no test coverage detected