aboutsummaryrefslogtreecommitdiffstats
path: root/src/main/headers
diff options
context:
space:
mode:
Diffstat (limited to 'src/main/headers')
-rw-r--r--src/main/headers/Actor.hpp2
-rw-r--r--src/main/headers/Bullet.hpp3
-rw-r--r--src/main/headers/Item.hpp2
-rw-r--r--src/main/headers/Stick.hpp2
4 files changed, 5 insertions, 4 deletions
diff --git a/src/main/headers/Actor.hpp b/src/main/headers/Actor.hpp
index 90535b1..1e160f6 100644
--- a/src/main/headers/Actor.hpp
+++ b/src/main/headers/Actor.hpp
@@ -9,8 +9,8 @@
class Actor
{
public:
- const unsigned maxHp;
const std::string name;
+ const unsigned maxHp;
Actor() = delete;
virtual ~Actor();
diff --git a/src/main/headers/Bullet.hpp b/src/main/headers/Bullet.hpp
index 6ab5dbe..b12c614 100644
--- a/src/main/headers/Bullet.hpp
+++ b/src/main/headers/Bullet.hpp
@@ -2,12 +2,13 @@
#define BULLET_HPP
#include "Item.hpp"
+#include "RangedWeapon.hpp"
class Bullet : protected Item
{
public:
virtual bool use(RangedWeapon &weapon);
- virtual bool decreaseAmount(int qnt);
+ virtual bool decreaseAmount(unsigned qnt);
};
#endif
diff --git a/src/main/headers/Item.hpp b/src/main/headers/Item.hpp
index 56f8733..ce0c921 100644
--- a/src/main/headers/Item.hpp
+++ b/src/main/headers/Item.hpp
@@ -31,7 +31,7 @@ protected:
const std::string _name;
- Item(Type t, const std::string &name) : _name(name), type(t) {}
+ Item(Type t, const std::string &name) : type(t), _name(name) {}
};
#endif
diff --git a/src/main/headers/Stick.hpp b/src/main/headers/Stick.hpp
index 724e36d..6421560 100644
--- a/src/main/headers/Stick.hpp
+++ b/src/main/headers/Stick.hpp
@@ -6,7 +6,7 @@
class Stick : public Item
{
public:
- Stick(const std::string &name);
+ Stick(const std::string &name, int maxUses);
bool use(Actor &user, Actor &actor);
protected: