54 lines
908 B
C
54 lines
908 B
C
|
#pragma once
|
||
|
|
||
|
#include "Com.h"
|
||
|
|
||
|
class Stats : public Com
|
||
|
{
|
||
|
private:
|
||
|
uint8_t level;
|
||
|
uint8_t strength;
|
||
|
uint8_t dexterity;
|
||
|
uint8_t constitution;
|
||
|
uint8_t intelligence;
|
||
|
uint8_t wisdom;
|
||
|
uint8_t charisma;
|
||
|
uint8_t maxHealth;
|
||
|
uint8_t health;
|
||
|
|
||
|
public:
|
||
|
Stats();
|
||
|
|
||
|
Stats(uint8_t strength, uint8_t dexterity, uint8_t constitution, uint8_t intelligence, uint8_t wisdom, uint8_t charisma);
|
||
|
|
||
|
Stats(Stats&& stats) noexcept;
|
||
|
|
||
|
Stats(const Stats& stats);
|
||
|
|
||
|
Stats& operator=(Stats&& stats) noexcept;
|
||
|
|
||
|
Stats& operator=(const Stats& stats);
|
||
|
|
||
|
uint8_t GetLevel() const;
|
||
|
|
||
|
uint8_t GetStrength() const;
|
||
|
|
||
|
uint8_t GetDexterity() const;
|
||
|
|
||
|
uint8_t GetConstitution() const;
|
||
|
|
||
|
uint8_t GetIntelligence() const;
|
||
|
|
||
|
uint8_t GetWisdom() const;
|
||
|
|
||
|
uint8_t GetCharisma() const;
|
||
|
|
||
|
uint8_t GetMaxHealth() const;
|
||
|
|
||
|
void SetHealth(uint8_t newHealth);
|
||
|
|
||
|
void TakeDmg(uint8_t dmg);
|
||
|
|
||
|
void Heal(uint8_t heal);
|
||
|
|
||
|
uint8_t GetHealth() const;
|
||
|
};
|