From 1649cf2bb9cf288aa37b94054258d6bad9fc5b55 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tomasz=20Zieli=C5=84ski?= Date: Fri, 9 Sep 2022 21:01:46 +0200 Subject: [PATCH] misc comments --- AI/Nullkiller/Engine/PriorityEvaluator.cpp | 2 ++ lib/mapObjects/CGHeroInstance.cpp | 3 +-- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/AI/Nullkiller/Engine/PriorityEvaluator.cpp b/AI/Nullkiller/Engine/PriorityEvaluator.cpp index e3f1c1715..6c47b6965 100644 --- a/AI/Nullkiller/Engine/PriorityEvaluator.cpp +++ b/AI/Nullkiller/Engine/PriorityEvaluator.cpp @@ -92,6 +92,8 @@ int32_t estimateTownIncome(CCallback * cb, const CGObjectInstance * target, cons TResources getCreatureBankResources(const CGObjectInstance * target, const CGHeroInstance * hero) { + //Fixme: unused variable hero + auto objectInfo = VLC->objtypeh->getHandlerFor(target->ID, target->subID)->getObjectInfo(target->appearance); CBankInfo * bankInfo = dynamic_cast(objectInfo.get()); auto resources = bankInfo->getPossibleResourcesReward(); diff --git a/lib/mapObjects/CGHeroInstance.cpp b/lib/mapObjects/CGHeroInstance.cpp index 2e40ea49d..ac97dd901 100644 --- a/lib/mapObjects/CGHeroInstance.cpp +++ b/lib/mapObjects/CGHeroInstance.cpp @@ -450,9 +450,8 @@ void CGHeroInstance::onHeroVisit(const CGHeroInstance * h) const { int txt_id; - if (cb->getHeroCount(h->tempOwner, false) < VLC->modh->settings.MAX_HEROES_ON_MAP_PER_PLAYER)//GameConstants::MAX_HEROES_PER_PLAYER) //free hero slot + if (cb->getHeroCount(h->tempOwner, false) < VLC->modh->settings.MAX_HEROES_ON_MAP_PER_PLAYER)//free hero slot { - cb->changeObjPos(id,pos+int3(1,0,0),0); //update hero parameters SetMovePoints smp; smp.hid = id;