Remove creature classes from Library lib, merged with Battling lib.
All checks were successful
continuous-integration/drone/push Build is passing
All checks were successful
continuous-integration/drone/push Build is passing
This commit is contained in:
29
src/Battling/Models/LearnedAttack.hpp
Normal file
29
src/Battling/Models/LearnedAttack.hpp
Normal file
@@ -0,0 +1,29 @@
|
||||
#ifndef CREATURELIB_LEARNEDATTACK_HPP
|
||||
#define CREATURELIB_LEARNEDATTACK_HPP
|
||||
|
||||
#include "../../Library/Attacks/AttackData.hpp"
|
||||
#include "AttackLearnMethod.hpp"
|
||||
|
||||
namespace CreatureLib::Battling{
|
||||
class LearnedAttack {
|
||||
const Library::AttackData* _attack;
|
||||
uint8_t _maxUses;
|
||||
uint8_t _remainingUses;
|
||||
AttackLearnMethod _learnMethod;
|
||||
public:
|
||||
LearnedAttack(Library::AttackData* attack, uint8_t maxUses, AttackLearnMethod learnMethod);
|
||||
|
||||
const Library::AttackData* GetAttack() const;
|
||||
uint8_t GetMaxUses() const;
|
||||
uint8_t GetRemainingUses() const;
|
||||
AttackLearnMethod GetLearnMethod() const;
|
||||
|
||||
bool TryUse(uint8_t uses);
|
||||
void DecreaseUses(uint8_t amount);
|
||||
void RestoreUses(uint8_t amount);
|
||||
void RestoreUses();
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
#endif //CREATURELIB_LEARNEDATTACK_HPP
|
||||
Reference in New Issue
Block a user