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

Method execute

bwapi/BWScriptEmulator/Send_Suicide.cpp:9–26  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

7IMPLEMENT(Send_Suicide);
8
9bool Send_Suicide::execute(aithread &thread) const
10{
11 // Retrieve parameters
12 BYTE bSuicideType;
13 thread.readTuple( std::tie(bSuicideType) );
14
15 // Execute
16 memset(MainController.attackGroups, 0, sizeof(MainController.attackGroups));
17 MainController.wAttackGroup = 0;
18 // MainController.dwAttackTime = 0;
19 // AttackClear();
20 // SendSuicide(bSuicideType);
21 MainController.dwAttackTime = Broodwar->elapsedTime() - 175;
22
23 // Save debug info and return
24 thread.saveDebug(Text::Red, this->getOpcode(), "%u", bSuicideType);
25 return true;
26}

Callers

nothing calls this directly

Calls 4

saveDebugMethod · 0.80
getOpcodeMethod · 0.80
readTupleMethod · 0.45
elapsedTimeMethod · 0.45

Tested by

no test coverage detected