Functions.h 1.0 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152
  1. /*
  2. * Functions.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 "Zone.h"
  12. #include <boost/heap/priority_queue.hpp> //A*
  13. VCMI_LIB_NAMESPACE_BEGIN
  14. class RmgMap;
  15. class ObjectManager;
  16. class ObjectTemplate;
  17. class CMapGenerator;
  18. class rmgException : public std::exception
  19. {
  20. std::string msg;
  21. public:
  22. explicit rmgException(const std::string& _Message) : msg(_Message)
  23. {
  24. }
  25. virtual ~rmgException() throw ()
  26. {
  27. };
  28. const char *what() const throw () override
  29. {
  30. return msg.c_str();
  31. }
  32. };
  33. rmg::Tileset collectDistantTiles(const Zone & zone, int distance);
  34. void createBorder(RmgMap & gen, Zone & zone);
  35. void paintZoneTerrain(const Zone & zone, CRandomGenerator & generator, RmgMap & map, TerrainId terrainType);
  36. void initTerrainType(Zone & zone, CMapGenerator & gen);
  37. int chooseRandomAppearance(CRandomGenerator & generator, si32 ObjID, TerrainId terrain);
  38. VCMI_LIB_NAMESPACE_END