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

Method checkPosition

bwapi/TestAIModule/Source/UseTechTest.cpp:316–329  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

314 currentEnergy = user->getEnergy();
315}
316void UseTechTest::checkPosition()
317{
318 if (targetUnit != NULL)
319 {
320 if (user->getDistance(targetUnit->getPosition())<32*4)
321 {
322 isInPosition = true;
323 }
324 }
325 else
326 {
327 isInPosition = true;
328 }
329}
330void UseTechTest::useTech()
331{
332 bool used=false;

Callers

nothing calls this directly

Calls 2

getDistanceMethod · 0.45
getPositionMethod · 0.45

Tested by

no test coverage detected