aboutsummaryrefslogtreecommitdiff
path: root/src/openvic-simulation/military
diff options
context:
space:
mode:
author hop311 <hop3114@gmail.com>2024-10-23 01:21:25 +0200
committer hop311 <hop3114@gmail.com>2024-10-23 01:21:25 +0200
commiteca580673aec46cd6e730e7307c13afb858efd94 (patch)
tree8ad859f8c3b4cad664a7a3e4cd93edbbed60bb5f /src/openvic-simulation/military
parentc88cf59997529cbca008f9a2b629822de9deaa2a (diff)
[Work-In-Progress] Add ModifierEffectMappingmodifier-effect-mappings
Diffstat (limited to 'src/openvic-simulation/military')
-rw-r--r--src/openvic-simulation/military/LeaderTrait.cpp9
1 files changed, 2 insertions, 7 deletions
diff --git a/src/openvic-simulation/military/LeaderTrait.cpp b/src/openvic-simulation/military/LeaderTrait.cpp
index 7835636..1694828 100644
--- a/src/openvic-simulation/military/LeaderTrait.cpp
+++ b/src/openvic-simulation/military/LeaderTrait.cpp
@@ -34,15 +34,10 @@ bool LeaderTraitManager::load_leader_traits_file(ModifierManager const& modifier
[this, &modifier_manager, type](std::string_view trait_identifier, ast::NodeCPtr value) -> bool {
using enum Modifier::modifier_type_t;
- static const string_set_t allowed_modifiers = {
- "attack", "defence leader", "morale", "organisation", "reconnaissance",
- "speed", "attrition", "experience", "reliability"
- };
-
ModifierValue modifiers;
- bool ret = modifier_manager.expect_whitelisted_modifier_value(
- move_variable_callback(modifiers), LEADER, allowed_modifiers
+ bool ret = modifier_manager.expect_modifier_value(
+ move_variable_callback(modifiers), LEADER
)(value);
ret &= add_leader_trait(trait_identifier, type, std::move(modifiers));