mirror of
https://github.com/vcmi/vcmi.git
synced 2024-11-28 08:48:48 +02:00
22 lines
459 B
C++
22 lines
459 B
C++
#include "StdInc.h"
|
|
#include "CObstacleInstance.h"
|
|
#include "CHeroHandler.h"
|
|
#include "VCMI_Lib.h"
|
|
|
|
CObstacleInstance::CObstacleInstance()
|
|
{
|
|
isAbsoluteObstacle = false;
|
|
}
|
|
|
|
const CObstacleInfo & CObstacleInstance::getInfo() const
|
|
{
|
|
if(isAbsoluteObstacle)
|
|
return VLC->heroh->absoluteObstacles[ID];
|
|
|
|
return VLC->heroh->obstacles[ID];
|
|
}
|
|
|
|
std::vector<BattleHex> CObstacleInstance::getBlocked() const
|
|
{
|
|
return getInfo().getBlocked(pos);
|
|
} |