TileInfo.h 939 B

123456789101112131415161718192021222324252627282930313233343536373839404142434445
  1. /*
  2. * TileInfo.h, part of VCMI engine
  3. *
  4. * Authors: listed in file AUTHORS in main folder
  5. *
  6. * License: GNU General Public License v2.0 or later
  7. * Full text of license available in license.txt file, in main folder
  8. *
  9. */
  10. #pragma once
  11. #include "../GameConstants.h"
  12. //#include "../TerrainHandler.h"
  13. VCMI_LIB_NAMESPACE_BEGIN
  14. class TileInfo
  15. {
  16. public:
  17. TileInfo();
  18. float getNearestObjectDistance() const;
  19. void setNearestObjectDistance(float value);
  20. bool isBlocked() const;
  21. bool shouldBeBlocked() const;
  22. bool isPossible() const;
  23. bool isFree() const;
  24. bool isUsed() const;
  25. bool isRoad() const;
  26. void setOccupied(ETileType::ETileType value);
  27. TerrainId getTerrainType() const;
  28. ETileType::ETileType getTileType() const;
  29. void setTerrainType(TerrainId value);
  30. void setRoadType(RoadId type);
  31. private:
  32. float nearestObjectDistance;
  33. ETileType::ETileType occupied;
  34. TerrainId terrain;
  35. RoadId roadType;
  36. };
  37. VCMI_LIB_NAMESPACE_END