zloop1982 / bwta

Automatically exported from code.google.com/p/bwta
GNU Lesser General Public License v3.0
0 stars 0 forks source link

targets parameter of getNearestTilePosition should be const #3

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
targets parameter of
std::pair<BWAPI::TilePosition, double> getNearestTilePosition
(BWAPI::TilePosition start, std::set<BWAPI::TilePosition>& targets) should 
be marked as const.

Original issue reported on code.google.com by tin...@gmail.com on 7 Jan 2010 at 4:34

GoogleCodeExporter commented 9 years ago
I am using this function at the moment, why it should be marked as const? 
It is giving me a wrong result everytime. I upgraded to bwapi 2.7 and now I 
can't 
even build the solution. BWTA is giving two unresolved externals.

ExampleAIModule.obj : error LNK2019: unresolved external symbol "struct 
std::pair<class BWAPI::TilePosition,double> __cdecl BWTA::getNearestTilePosition
(class BWAPI::TilePosition,class std::set<class BWAPI::TilePosition,struct 
std::less<class BWAPI::TilePosition>,class std::allocator<class 
BWAPI::TilePosition> 
> &)" (?getNearestTilePosition@BWTA@@YA?AU?
$pair@VTilePosition@BWAPI@@N@std@@VTilePosition@BWAPI@@AAV?
$set@VTilePosition@BWAPI@@U?$less@VTilePosition@BWAPI@@@std@@V?
$allocator@VTilePosition@BWAPI@@@4@@3@@Z) referenced in function __catch$?
onFrame@ExampleAIModule@@UAEXXZ$0
3>ExampleAIModule.obj : error LNK2019: unresolved external symbol "public: 
__thiscall BWTA::Polygon::Polygon(class BWTA::Polygon const &)" (??
0Polygon@BWTA@@QAE@ABV01@@Z) referenced in function "public: virtual void 
__thiscall 
ExampleAIModule::onFrame(void)" (?onFrame@ExampleAIModule@@UAEXXZ)
3>D:\Program Files (x86)
\Starcraft\Ourproxybot\src\RugAIModule\trunk\Debug\RugAIModule.dll : fatal 
error 
LNK1120: 2 unresolved externals

As you see the first one is related to the getNearestTilePosition and the 
second one 
is for Polygon in the Analyze part of the function.

Original comment by shantia....@gmail.com on 26 May 2010 at 10:32

GoogleCodeExporter commented 9 years ago

Original comment by lowerlo...@gmail.com on 17 Nov 2010 at 4:51