ConnectionsPlacer.h 933 B

123456789101112131415161718192021222324252627282930313233343536373839
  1. /*
  2. * ConnectionsPlacer.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 "RmgArea.h"
  13. VCMI_LIB_NAMESPACE_BEGIN
  14. class ConnectionsPlacer: public Modificator
  15. {
  16. public:
  17. MODIFICATOR(ConnectionsPlacer);
  18. void process() override;
  19. void init() override;
  20. void addConnection(const rmg::ZoneConnection& connection);
  21. void selfSideDirectConnection(const rmg::ZoneConnection & connection);
  22. void selfSideIndirectConnection(const rmg::ZoneConnection & connection);
  23. void otherSideConnection(const rmg::ZoneConnection & connection);
  24. protected:
  25. void collectNeighbourZones();
  26. protected:
  27. std::vector<rmg::ZoneConnection> dConnections, dCompleted;
  28. std::map<TRmgTemplateZoneId, rmg::Tileset> dNeighbourZones;
  29. };
  30. VCMI_LIB_NAMESPACE_END