From 8533ee3256f76932db7c1d5cd0d5e568da04a519 Mon Sep 17 00:00:00 2001 From: Arseniy Shestakov Date: Thu, 11 Aug 2016 14:54:58 +0300 Subject: [PATCH] VCAI::validateVisitableObjs: drop unused code that For whatever reason it's not removed at compile time and still wasting CPU. --- AI/VCAI/VCAI.cpp | 12 ------------ 1 file changed, 12 deletions(-) diff --git a/AI/VCAI/VCAI.cpp b/AI/VCAI/VCAI.cpp index f673b8f1f..50ee96788 100644 --- a/AI/VCAI/VCAI.cpp +++ b/AI/VCAI/VCAI.cpp @@ -1691,9 +1691,6 @@ void VCAI::clearPathsInfo() void VCAI::validateVisitableObjs() { - std::vector hlp; - retreiveVisitableObjs(hlp, true); - std::string errorMsg; auto shouldBeErased = [&](const CGObjectInstance *obj) -> bool { @@ -1701,15 +1698,6 @@ void VCAI::validateVisitableObjs() return !cb->getObj(obj->id, false); // no verbose output needed as we check object visibility else return true; - - //why would we have our local logic for object checks? use cb! - - //if(!vstd::contains(hlp, obj)) - //{ - // logAi->errorStream() << helperObjInfo[obj].name << " at " << helperObjInfo[obj].pos << errorMsg; - // return true; - //} - //return false; }; //errorMsg is captured by ref so lambda will take the new text