MapFeaturesH3M.h 1.6 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273
  1. /*
  2. * MapFeaturesH3M.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. VCMI_LIB_NAMESPACE_BEGIN
  12. enum class EMapFormat : uint8_t;
  13. struct MapFormatFeaturesH3M
  14. {
  15. public:
  16. static MapFormatFeaturesH3M find(EMapFormat format, uint32_t hotaVersion);
  17. static MapFormatFeaturesH3M getFeaturesROE();
  18. static MapFormatFeaturesH3M getFeaturesAB();
  19. static MapFormatFeaturesH3M getFeaturesSOD();
  20. static MapFormatFeaturesH3M getFeaturesWOG();
  21. static MapFormatFeaturesH3M getFeaturesHOTA(uint32_t hotaVersion);
  22. MapFormatFeaturesH3M() = default;
  23. // number of bytes in bitmask of appropriate type
  24. int factionsBytes;
  25. int heroesBytes;
  26. int artifactsBytes;
  27. int resourcesBytes;
  28. int skillsBytes;
  29. int spellsBytes;
  30. int buildingsBytes;
  31. // total number of elements of appropriate type
  32. int factionsCount;
  33. int heroesCount;
  34. int heroesPortraitsCount;
  35. int artifactsCount;
  36. int resourcesCount;
  37. int creaturesCount;
  38. int spellsCount;
  39. int skillsCount;
  40. int terrainsCount;
  41. int roadsCount;
  42. int riversCount;
  43. int artifactSlotsCount;
  44. int buildingsCount;
  45. // identifier that should be treated as "invalid", usually - '-1'
  46. int heroIdentifierInvalid;
  47. int artifactIdentifierInvalid;
  48. int creatureIdentifierInvalid;
  49. int spellIdentifierInvalid;
  50. // features from which map format are available
  51. bool levelROE = false;
  52. bool levelAB = false;
  53. bool levelSOD = false;
  54. bool levelWOG = false;
  55. bool levelHOTA0 = false;
  56. bool levelHOTA1 = false;
  57. bool levelHOTA3 = false;
  58. };
  59. VCMI_LIB_NAMESPACE_END