Clone of Bael'Zharon's Respite @ https://github.com/boardwalk/bzr

Property.h 2.1KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697
  1. /*
  2. * Bael'Zharon's Respite
  3. * Copyright (C) 2014 Daniel Skorupski
  4. *
  5. * This program is free software; you can redistribute it and/or modify
  6. * it under the terms of the GNU General Public License as published by
  7. * the Free Software Foundation; either version 2 of the License, or
  8. * (at your option) any later version.
  9. * This program is distributed in the hope that it will be useful,
  10. * but WITHOUT ANY WARRANTY; withuot even the implied warranty of
  11. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  12. * GNU General Public License for more details.
  13. *
  14. * You should have received a copy of the GNU General Public License along
  15. * with this program; if not, write to the Free Software Foundation, Inc.,
  16. * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
  17. */
  18. #ifndef BZR_PROPERTY_H
  19. #define BZR_PROPERTY_H
  20. #define ENTRY(key, value) k##key = value,
  21. enum class BoolProperty : uint32_t
  22. {
  23. #include "properties/BoolProperty.inc"
  24. };
  25. enum class StringProperty : uint32_t
  26. {
  27. #include "properties/StringProperty.inc"
  28. };
  29. enum class IntProperty : uint32_t
  30. {
  31. #include "properties/IntProperty.inc"
  32. };
  33. enum class Int64Property : uint32_t
  34. {
  35. #include "properties/Int64Property.inc"
  36. };
  37. enum class FloatProperty : uint32_t
  38. {
  39. #include "properties/FloatProperty.inc"
  40. };
  41. enum class PositionProperty : uint32_t
  42. {
  43. #include "properties/PositionProperty.inc"
  44. };
  45. enum class IIDProperty : uint32_t
  46. {
  47. #include "properties/IIDProperty.inc"
  48. };
  49. enum class DIDProperty : uint32_t
  50. {
  51. #include "properties/DIDProperty.inc"
  52. };
  53. enum class SkillProperty : uint32_t
  54. {
  55. #include "properties/SkillProperty.inc"
  56. };
  57. enum class AttributeProperty : uint32_t
  58. {
  59. #include "properties/AttributeProperty.inc"
  60. };
  61. enum class Attribute2ndProperty : uint32_t
  62. {
  63. #include "properties/Attribute2ndProperty.inc"
  64. };
  65. #undef ENTRY
  66. #define DECLARE_GET(t) \
  67. const string& get##t##PropertyName(t##Property property);
  68. DECLARE_GET(Bool)
  69. DECLARE_GET(String)
  70. DECLARE_GET(Int)
  71. DECLARE_GET(Int64)
  72. DECLARE_GET(Float)
  73. DECLARE_GET(Position)
  74. DECLARE_GET(IID)
  75. DECLARE_GET(DID)
  76. DECLARE_GET(Skill)
  77. DECLARE_GET(Attribute)
  78. DECLARE_GET(Attribute2nd)
  79. #undef DECLARE_GET
  80. #endif