diff options
author | zaaarf <zaaarf@proton.me> | 2023-11-22 17:16:34 +0100 |
---|---|---|
committer | zaaarf <zaaarf@proton.me> | 2023-11-22 17:16:34 +0100 |
commit | 1683859e333f98fb63f1c72d926bb366a3b89f0b (patch) | |
tree | e11dde918a7f1f228d3383ba8f9287385e43b4f5 /src/openvic-simulation/politics/Issue.hpp | |
parent | 5c6caf6fbb7c606f4ebe0c397cc15c97d776f13d (diff) |
chore: use PROPERTY and its variants when possible
Diffstat (limited to 'src/openvic-simulation/politics/Issue.hpp')
-rw-r--r-- | src/openvic-simulation/politics/Issue.hpp | 19 |
1 files changed, 6 insertions, 13 deletions
diff --git a/src/openvic-simulation/politics/Issue.hpp b/src/openvic-simulation/politics/Issue.hpp index 84aa886..0dceae9 100644 --- a/src/openvic-simulation/politics/Issue.hpp +++ b/src/openvic-simulation/politics/Issue.hpp @@ -25,7 +25,7 @@ namespace OpenVic { friend struct IssueManager; private: - IssueGroup const& group; + IssueGroup const& PROPERTY(group); // TODO: policy modifiers, policy rule changes @@ -34,7 +34,6 @@ namespace OpenVic { public: Issue(Issue&&) = default; - IssueGroup const& get_group() const; }; // Reform type (i.e. political_issues) @@ -56,17 +55,14 @@ namespace OpenVic { friend struct IssueManager; private: - ReformType const& type; - const bool ordered; // next_step_only - const bool administrative; + ReformType const& PROPERTY(type); + const bool PROPERTY_CUSTOM_NAME(ordered, is_ordered); // next_step_only + const bool PROPERTY_CUSTOM_NAME(administrative, is_administrative); ReformGroup(std::string_view identifier, ReformType const& type, bool ordered, bool administrative); public: ReformGroup(ReformGroup&&) = default; - ReformType const& get_type() const; - bool is_ordered() const; - bool is_administrative() const; }; // Reform (i.e. yes_slavery) @@ -74,8 +70,8 @@ namespace OpenVic { friend struct IssueManager; private: - ReformGroup const& reform_group; // stores an already casted reference - const size_t ordinal; // assigned by the parser to allow policy sorting + ReformGroup const& PROPERTY(reform_group); // stores an already casted reference + const size_t PROPERTY(ordinal); // assigned by the parser to allow policy sorting Reform(std::string_view new_identifier, ReformGroup const& group, size_t ordinal); @@ -83,9 +79,6 @@ namespace OpenVic { public: Reform(Reform&&) = default; - ReformGroup const& get_reform_group() const; - ReformType const& get_type() const; - size_t get_ordinal() const; }; // Issue manager - holds the registries |