Remove creature classes from Library lib, merged with Battling lib.
All checks were successful
continuous-integration/drone/push Build is passing

This commit is contained in:
2019-10-24 13:37:55 +02:00
parent bb8978314f
commit 9588236183
24 changed files with 310 additions and 337 deletions

View 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