1
0
mirror of https://github.com/vcmi/vcmi.git synced 2025-09-16 09:26:28 +02:00

replaced references to SectorMap with shared_ptr to avoid data races in AI code

This commit is contained in:
Ivan Savenko
2015-12-04 00:10:51 +02:00
parent 73b4188fab
commit 2e56b547ee
5 changed files with 24 additions and 24 deletions

View File

@@ -484,7 +484,7 @@ float FuzzyHelper::evaluate (Goals::ClearWayTo & g)
if (!g.hero.h)
throw cannotFulfillGoalException("ClearWayTo called without hero!");
int3 t = ai->getCachedSectorMap(g.hero).firstTileToGet(g.hero, g.tile);
int3 t = ai->getCachedSectorMap(g.hero)->firstTileToGet(g.hero, g.tile);
if (t.valid())
{