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

Method getForceID

bwapi/BWAPI/Source/BWAPI/Server.cpp:684–694  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

682 }
683
684 int Server::getForceID(Force force)
685 {
686 if ( !force )
687 return -1;
688 if (forceLookup.find(force) == forceLookup.end())
689 {
690 forceLookup[force] = (int)(forceVector.size());
691 forceVector.push_back(force);
692 }
693 return forceLookup[force];
694 }
695 Force Server::getForce(int id) const
696 {
697 if (forceVector.size() <= static_cast<unsigned>(id))

Callers

nothing calls this directly

Calls 2

endMethod · 0.80
sizeMethod · 0.45

Tested by

no test coverage detected