aboutsummaryrefslogtreecommitdiff
path: root/src/openvic-simulation/scripts/Condition.hpp
diff options
context:
space:
mode:
author hop311 <hop3114@gmail.com>2024-06-13 00:24:00 +0200
committer hop311 <hop3114@gmail.com>2024-06-13 00:24:00 +0200
commit4b39e77304094708d5c503b6a221386408cc4409 (patch)
tree7ba5a06714c267185dd3a59aabc6556a105c122f /src/openvic-simulation/scripts/Condition.hpp
parentc0ba822ee46551a40ad6b43e8f56b80e27ae35b5 (diff)
Separated GameManager into Definition and Instance Managersinstance-definition-managers
Diffstat (limited to 'src/openvic-simulation/scripts/Condition.hpp')
-rw-r--r--src/openvic-simulation/scripts/Condition.hpp16
1 files changed, 9 insertions, 7 deletions
diff --git a/src/openvic-simulation/scripts/Condition.hpp b/src/openvic-simulation/scripts/Condition.hpp
index 5aa45e8..748453f 100644
--- a/src/openvic-simulation/scripts/Condition.hpp
+++ b/src/openvic-simulation/scripts/Condition.hpp
@@ -10,7 +10,7 @@
namespace OpenVic {
struct ConditionManager;
struct ConditionScript;
- struct GameManager;
+ struct DefinitionManager;
enum class value_type_t : uint8_t {
NO_TYPE = 0,
@@ -222,7 +222,9 @@ namespace OpenVic {
using real_t = fixed_point_t;
using identifier_real_t = std::pair<std::string, real_t>;
using condition_list_t = std::vector<ConditionNode>;
- using value_t = std::variant<string_t, boolean_t, double_boolean_t, integer_t, real_t, identifier_real_t, condition_list_t>;
+ using value_t = std::variant<
+ string_t, boolean_t, double_boolean_t, integer_t, real_t, identifier_real_t, condition_list_t
+ >;
private:
Condition const* PROPERTY(condition);
@@ -252,25 +254,25 @@ namespace OpenVic {
);
NodeTools::callback_t<std::string_view> expect_parse_identifier(
- GameManager const& game_manager, identifier_type_t identifier_type,
+ DefinitionManager const& definition_manager, identifier_type_t identifier_type,
NodeTools::callback_t<HasIdentifier const*> callback
) const;
NodeTools::node_callback_t expect_condition_node(
- GameManager const& game_manager, Condition const& condition, scope_t this_scope,
+ DefinitionManager const& definition_manager, Condition const& condition, scope_t this_scope,
scope_t from_scope, scope_t cur_scope, NodeTools::callback_t<ConditionNode&&> callback
) const;
NodeTools::node_callback_t expect_condition_node_list(
- GameManager const& game_manager, scope_t this_scope, scope_t from_scope,
+ DefinitionManager const& definition_manager, scope_t this_scope, scope_t from_scope,
scope_t cur_scope, bool top_scope, NodeTools::callback_t<ConditionNode&&> callback
) const;
public:
- bool setup_conditions(GameManager const& game_manager);
+ bool setup_conditions(DefinitionManager const& definition_manager);
NodeTools::node_callback_t expect_condition_script(
- GameManager const& game_manager, scope_t initial_scope, scope_t this_scope, scope_t from_scope,
+ DefinitionManager const& definition_manager, scope_t initial_scope, scope_t this_scope, scope_t from_scope,
NodeTools::callback_t<ConditionNode&&> callback
) const;
};