1
0
mirror of https://github.com/vcmi/vcmi.git synced 2025-10-31 00:07:39 +02:00

Fixed CID 1197423, CID 1197567

This commit is contained in:
AlexVinS
2016-11-25 21:32:54 +03:00
parent 0e57825679
commit d81c611ad7

View File

@@ -18,6 +18,8 @@
CObstacleInstance::CObstacleInstance()
{
obstacleType = USUAL;
uniqueID = -1;
ID = -1;
}
CObstacleInstance::~CObstacleInstance()
@@ -33,13 +35,10 @@ const CObstacleInfo & CObstacleInstance::getInfo() const
return VLC->heroh->absoluteObstacles[ID];
case USUAL:
return VLC->heroh->obstacles[ID];
case MOAT:
assert(0);
default:
assert(0);
}
throw std::runtime_error("Unknown obstacle type in CObstacleInstance::getInfo()");
}
}
std::vector<BattleHex> CObstacleInstance::getBlockedTiles() const
{