From 14ebf20f23c5c1215658ab48e8ddf0e2530d5c04 Mon Sep 17 00:00:00 2001 From: Deukhoofd Date: Sun, 7 Mar 2021 19:04:15 +0100 Subject: [PATCH] Adds getter for pointer to script resolver on battle library. Signed-off-by: Deukhoofd --- CInterface/Battling/BattleLibrary.cpp | 1 + src/Battling/Library/BattleLibrary.hpp | 3 +++ 2 files changed, 4 insertions(+) diff --git a/CInterface/Battling/BattleLibrary.cpp b/CInterface/Battling/BattleLibrary.cpp index 6594ddc..6485453 100644 --- a/CInterface/Battling/BattleLibrary.cpp +++ b/CInterface/Battling/BattleLibrary.cpp @@ -18,3 +18,4 @@ SMART_GET_FUNC(BattleLibrary, GetStatCalculator, const BattleStatCalculator*); SMART_GET_FUNC(BattleLibrary, GetDamageLibrary, const DamageLibrary*); SMART_GET_FUNC(BattleLibrary, GetMiscLibrary, const MiscLibrary*); SMART_GET_FUNC(BattleLibrary, GetExperienceLibrary, const ExperienceLibrary*); +SMART_GET_FUNC(BattleLibrary, GetScriptResolver, ScriptResolver*); diff --git a/src/Battling/Library/BattleLibrary.hpp b/src/Battling/Library/BattleLibrary.hpp index f9cc69f..8602342 100644 --- a/src/Battling/Library/BattleLibrary.hpp +++ b/src/Battling/Library/BattleLibrary.hpp @@ -40,6 +40,9 @@ namespace CreatureLib::Battling { [[nodiscard]] const std::unique_ptr& GetExperienceLibrary() const noexcept { return _experienceLibrary; } + [[nodiscard]] const std::unique_ptr& GetScriptResolver() const noexcept { + return _scriptResolver; + } [[nodiscard]] BattleScript* LoadScript(ScriptCategory category, const ArbUt::StringView& scriptName) const; };