| 11 | running = false; |
| 12 | } |
| 13 | void MPHSTest::start() |
| 14 | { |
| 15 | if (fail) return; |
| 16 | running = true; |
| 17 | |
| 18 | int userCount = Broodwar->self()->completedUnitCount(unitType); |
| 19 | BWAssertF(userCount>=1,{fail=true;return;}); |
| 20 | for (Unit u : Broodwar->self()->getUnits()) |
| 21 | if (u->getType()==unitType) |
| 22 | unit = u; |
| 23 | |
| 24 | BWAssertF(unit!=NULL,{fail=true;return;}); |
| 25 | BWAssertF(unit->exists(),{fail=true;return;}); |
| 26 | BWAssertF(unit->stop(),{Broodwar->printf("%s",Broodwar->getLastError().c_str());fail=true;return;}); |
| 27 | startFrame = Broodwar->getFrameCount()+100; |
| 28 | nextFrame = Broodwar->getFrameCount(); |
| 29 | |
| 30 | } |
| 31 | void MPHSTest::update() |
| 32 | { |
| 33 | if (running == false) return; |
no test coverage detected