diff options
author | hop311 <hop3114@gmail.com> | 2024-08-11 00:40:07 +0200 |
---|---|---|
committer | hop311 <hop3114@gmail.com> | 2024-08-14 00:07:46 +0200 |
commit | 7e05aaccf0e13299702ddeed17661831c3ddc692 (patch) | |
tree | b85022a240a4a24c0ee0fd44cd59ff6bc112c18f /src/openvic-simulation/misc/SongChance.hpp | |
parent | 9f9c5844bfedc5e366a35cdba386027fb9f3a14a (diff) |
Assorted minor fixes (clang-format.sh shebang, parse national foci scripts, factor song chance, update openvic-dataloader)assorted-fixes
Diffstat (limited to 'src/openvic-simulation/misc/SongChance.hpp')
-rw-r--r-- | src/openvic-simulation/misc/SongChance.hpp | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/src/openvic-simulation/misc/SongChance.hpp b/src/openvic-simulation/misc/SongChance.hpp index f92af7a..dc7d929 100644 --- a/src/openvic-simulation/misc/SongChance.hpp +++ b/src/openvic-simulation/misc/SongChance.hpp @@ -1,19 +1,23 @@ #pragma once -#include <openvic-simulation/types/IdentifierRegistry.hpp> -#include <openvic-simulation/scripts/ConditionalWeight.hpp> +#include "openvic-simulation/types/IdentifierRegistry.hpp" +#include "openvic-simulation/scripts/ConditionalWeight.hpp" namespace OpenVic { /*For music/Songs.txt if it exists*/ struct SongChanceManager; + struct SongChance : HasIdentifier { - private: friend struct SongChanceManager; + + private: std::string PROPERTY(file_name); ConditionalWeight PROPERTY(chance); + SongChance(size_t new_index, std::string_view new_filename, ConditionalWeight&& new_chance); + bool parse_scripts(DefinitionManager const& definition_manager); - + public: SongChance(SongChance&&) = default; }; |