diff options
author | Nao Pross <naopross@thearcway.org> | 2018-02-17 22:08:18 +0100 |
---|---|---|
committer | Nao Pross <naopross@thearcway.org> | 2018-02-17 22:08:18 +0100 |
commit | 7ec2e0fbd6c53faa52ca0e6f2e8e172d3556c81d (patch) | |
tree | 3ce33e8d1b83e3adf9b7998fbfc206014e9250e7 /src/main/headers | |
parent | Add all warning and thread them as errors (diff) | |
download | Subconscious-old-7ec2e0fbd6c53faa52ca0e6f2e8e172d3556c81d.tar.gz Subconscious-old-7ec2e0fbd6c53faa52ca0e6f2e8e172d3556c81d.zip |
Fix all warnings (errors with -Werror)
Diffstat (limited to '')
-rw-r--r-- | src/main/headers/Actor.hpp | 2 | ||||
-rw-r--r-- | src/main/headers/Bullet.hpp | 3 | ||||
-rw-r--r-- | src/main/headers/Item.hpp | 2 | ||||
-rw-r--r-- | src/main/headers/Stick.hpp | 2 |
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: |