2020-01-02 17:02:40 +00:00
|
|
|
#ifndef PKMNLIB_BATTLELIBRARY_HPP
|
|
|
|
#define PKMNLIB_BATTLELIBRARY_HPP
|
|
|
|
|
2020-02-08 18:22:29 +00:00
|
|
|
#include <CreatureLib/Battling/Library/BattleLibrary.hpp>
|
2020-01-02 17:02:40 +00:00
|
|
|
#include "../../Library/PokemonLibrary.hpp"
|
2020-01-26 14:18:04 +00:00
|
|
|
#include "DamageLibrary.hpp"
|
2020-05-20 14:05:52 +00:00
|
|
|
#include "ExperienceLibrary.hpp"
|
2020-04-22 14:10:13 +00:00
|
|
|
#include "MiscLibrary.hpp"
|
2021-06-27 15:11:37 +00:00
|
|
|
#include "ScriptResolver.hpp"
|
2020-01-05 14:18:30 +00:00
|
|
|
#include "StatCalculator.hpp"
|
2020-01-02 17:02:40 +00:00
|
|
|
|
|
|
|
namespace PkmnLib::Battling {
|
2020-10-15 16:13:00 +00:00
|
|
|
class BattleLibrary final : public CreatureLib::Battling::BattleLibrary {
|
2020-01-02 17:02:40 +00:00
|
|
|
public:
|
2022-03-25 18:08:42 +00:00
|
|
|
BattleLibrary(Library::PokemonLibrary* non_null staticLib, StatCalculator* non_null statCalculator,
|
|
|
|
DamageLibrary* non_null damageLibrary,
|
|
|
|
PkmnLib::Battling::ExperienceLibrary* non_null experienceLibrary,
|
|
|
|
ScriptResolver* non_null scriptResolver, PkmnLib::Battling::MiscLibrary* non_null miscLibrary)
|
2020-01-02 17:02:40 +00:00
|
|
|
: CreatureLib::Battling::BattleLibrary(staticLib, statCalculator, damageLibrary, experienceLibrary,
|
|
|
|
scriptResolver, miscLibrary) {}
|
|
|
|
|
2020-05-27 15:26:25 +00:00
|
|
|
const std::unique_ptr<const Library::LibrarySettings>& GetSettings() const {
|
|
|
|
return reinterpret_cast<const std::unique_ptr<const Library::LibrarySettings>&>(_staticLib->GetSettings());
|
2020-02-01 15:56:09 +00:00
|
|
|
}
|
|
|
|
|
2020-05-27 15:26:25 +00:00
|
|
|
const std::unique_ptr<const Library::PokemonLibrary>& GetStaticLib() const {
|
|
|
|
return reinterpret_cast<const std::unique_ptr<const Library::PokemonLibrary>&>(_staticLib);
|
2020-01-02 19:26:01 +00:00
|
|
|
}
|
|
|
|
|
2020-05-27 15:26:25 +00:00
|
|
|
const std::unique_ptr<const Library::SpeciesLibrary>& GetSpeciesLibrary() const {
|
|
|
|
return reinterpret_cast<const std::unique_ptr<const Library::SpeciesLibrary>&>(
|
|
|
|
_staticLib->GetSpeciesLibrary());
|
2020-01-02 17:02:40 +00:00
|
|
|
}
|
|
|
|
|
2020-05-27 15:26:25 +00:00
|
|
|
const std::unique_ptr<const Library::MoveLibrary>& GetMoveLibrary() const {
|
|
|
|
return reinterpret_cast<const std::unique_ptr<const Library::MoveLibrary>&>(_staticLib->GetAttackLibrary());
|
2020-01-18 13:35:08 +00:00
|
|
|
}
|
|
|
|
|
2020-05-27 15:26:25 +00:00
|
|
|
const std::unique_ptr<const Library::ItemLibrary>& GetItemLibrary() const {
|
|
|
|
return reinterpret_cast<const std::unique_ptr<const Library::ItemLibrary>&>(_staticLib->GetItemLibrary());
|
2020-01-02 17:02:40 +00:00
|
|
|
}
|
|
|
|
|
2020-06-02 18:37:21 +00:00
|
|
|
const ArbUt::BorrowedPtr<const Library::NatureLibrary> GetNatureLibrary() const {
|
|
|
|
return GetStaticLib()->GetNatureLibrary();
|
|
|
|
}
|
2020-01-11 21:30:23 +00:00
|
|
|
|
2022-03-25 18:08:42 +00:00
|
|
|
static PkmnLib::Battling::ScriptResolver* non_null CreateScriptResolver();
|
2020-01-02 17:02:40 +00:00
|
|
|
};
|
|
|
|
}
|
|
|
|
#endif // PKMNLIB_BATTLELIBRARY_HPP
|