PkmnLib/CInterface/Battling/BattleLibrary.cpp

18 lines
1.1 KiB
C++
Raw Normal View History

2020-04-29 17:46:24 +00:00
#include "../../src/Battling/Library/BattleLibrary.hpp"
#include "../Core.hpp"
using namespace PkmnLib::Battling;
2022-04-02 11:03:11 +00:00
export_func uint8_t PkmnLib_BattleLibrary_Construct(BattleLibrary*& out, PkmnLib::Library::PokemonLibrary* staticLib,
2020-04-29 17:46:24 +00:00
StatCalculator* statCalculator, DamageLibrary* damageLibrary,
2020-05-20 14:05:52 +00:00
ExperienceLibrary* experienceLibrary,
2021-06-27 15:11:37 +00:00
PkmnLib::Battling::ScriptResolver* scriptResolver,
2022-03-26 15:23:24 +00:00
MiscLibrary* miscLibrary, CaptureLibrary* captureLibrary) {
2020-04-29 17:46:24 +00:00
Try(out = new BattleLibrary(staticLib, statCalculator, damageLibrary, experienceLibrary, scriptResolver,
2022-03-26 15:23:24 +00:00
miscLibrary, captureLibrary));
2020-04-29 17:46:24 +00:00
}
2022-04-02 11:03:11 +00:00
export_func void PkmnLib_BattleLibrary_Destruct(BattleLibrary* p) { delete p; }
2022-03-26 15:23:24 +00:00
2022-04-02 11:03:11 +00:00
export_func uint8_t PkmnLib_CaptureLibrary_Construct(CaptureLibrary*& out) { Try(out = new CaptureLibrary()); }
export_func void PkmnLib_CaptureLibrary_Destruct(CaptureLibrary* p) { delete p; }