PkmnLib/src/Library/Moves/MoveLibrary.hpp

28 lines
978 B
C++
Raw Normal View History

2019-12-29 14:29:52 +00:00
#ifndef PKMNLIB_MOVELIBRARY_HPP
#define PKMNLIB_MOVELIBRARY_HPP
#include <Library/AttackLibrary.hpp>
#include "MoveData.hpp"
2019-12-29 14:29:52 +00:00
namespace PkmnLib::Library {
class MoveLibrary : public CreatureLib::Library::AttackLibrary {
public:
virtual const MoveData* operator[](const std::string& name) const { return GetAttack(name); }
const MoveData* GetMove(const std::string& name) const { return GetAttack(name); }
const MoveData* GetAttack(const std::string& name) const {
return reinterpret_cast<const MoveData*>(CreatureLib::Library::AttackLibrary::GetAttack(name));
}
void LoadAttack(const std::string& name, const MoveData* attack){
CreatureLib::Library::AttackLibrary::LoadAttack(name, attack);
}
void LoadMove(const std::string& name, const MoveData* attack){
CreatureLib::Library::AttackLibrary::LoadAttack(name, attack);
}
2019-12-29 14:29:52 +00:00
};
}
#endif // PKMNLIB_MOVELIBRARY_HPP