From 98558d01777e599399383fff1a028549b1056d22 Mon Sep 17 00:00:00 2001 From: mathusummut Date: Mon, 24 Sep 2018 15:19:05 +0200 Subject: [PATCH] Fixed unfinished building FOW bug --- source/glest_game/type_instances/unit.cpp | 2 +- source/glest_game/world/world.cpp | 4 +--- 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/source/glest_game/type_instances/unit.cpp b/source/glest_game/type_instances/unit.cpp index dc7f3a8e5..90477c53d 100644 --- a/source/glest_game/type_instances/unit.cpp +++ b/source/glest_game/type_instances/unit.cpp @@ -5479,7 +5479,7 @@ namespace Glest { } void Unit::exploreCells(bool forceRefresh) { - if (this->isOperative() == true) { + if (this->isAlive() == true) { const Vec2i & newPos = this->getCenteredPos(); int sightRange = this->getType()->getTotalSight(this->getTotalUpgrade()); diff --git a/source/glest_game/world/world.cpp b/source/glest_game/world/world.cpp index b0810a7d9..1b5367f72 100644 --- a/source/glest_game/world/world.cpp +++ b/source/glest_game/world/world.cpp @@ -2686,9 +2686,7 @@ namespace Glest { // compute fog of war render texture if (fogOfWar == true && faction->getTeam() == thisTeamIndex && - unit->isOperative() == true) { - - //printf("computeFow unit->isOperative() == true\n"); + unit->isAlive() == true) { const FowAlphaCellsLookupItem &cellList = unit->getCachedFow(); for (std::map::const_iterator iterMap = cellList.surfPosAlphaList.begin();